Skip to content

feat(tests): merge each change into a simulated fork in CI (#1924) - #1962

Merged
braboj merged 2 commits into
mainfrom
feat/fork-sync-job
Oct 17, 2026
Merged

braboj merged 2 commits into
mainfrom
feat/fork-sync-job

Conversation

@braboj

@braboj braboj commented Oct 17, 2026

Copy link
Copy Markdown
Collaborator

Closes #1924.

What

tests/run_fork_sync.py checks ADR-049's claim that a fork syncs with git merge upstream/main. It makes a fork from the merge base of HEAD and origin/main. The fork appends a stack (a renamed copy of the fixture) and its manifest entry, and adds a line to its own README, CLAUDE.md and CHANGELOG. The runner then merges in three scenarios:

ID Upstream side Owed
FS-01 Planted: appends its own stack at the manifest's end Conflict in templates/manifest.yaml only, caught
FS-02 Planted: edits the README under its title Conflict in README.md only, kept as the fork's
FS-03 HEAD (the PR's merge commit in CI), or a planted base: edit when HEAD adds nothing No conflict outside fork-owned files; smoke passes in the merged tree with SAIT_UPSTREAM_REF at the upstream side

The upstream change is the PR's own diff rather than a fixed synthetic edit, so every PR is checked for whether a fork can take it. Each simulated commit asserts that it changed exactly the files it claims to.

Spec SAIT-INT-MNF-06-001A, with rows in INDEX and CODIFICATION. There is a new step in smoke.yml, and the runner is listed in CLAUDE.md and PLAYBOOK.

Control

An upstream commit that gives core/quality.md the section ID fork-sync-stack, committed in a scratch worktree (the landing count went from 0 to 1):

  • upstream run_smoke.py SYS-02: PASS
  • run_fork_sync.py: FS-03 FAIL, with nested smoke 1 failed (SYS-02)

Checks run locally (py 3.12)

  • smoke: 35/35 PASS
  • fork sync: 3/3 PASS. On this branch, nested smoke passed 35/35
  • sync.py --check and resolve.py --check: clean
  • conformance: 8 failed locally, the same 8 as origin/main in a pinned worktree (environment-dependent). The one reading, core/git.md:1898, flags that this diff touches .github/workflows/smoke.yml, an off-limits path: it adds the CI step on purpose.

No CHANGELOG entry: the change is to this repository's own tests and CI, and no consuming project would notice it.

🤖 Generated with Claude Code

braboj and others added 2 commits October 17, 2026 15:28
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@braboj
braboj merged commit 07168f3 into main Oct 17, 2026
1 check passed
@braboj
braboj deleted the feat/fork-sync-job branch October 17, 2026 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a CI job that proves a fork stays mergeable with upstream

1 participant