Public: anyone can read this; the crew can change it.

A test proves a mirrored repository's branch moves only after its origin took the push, for create and delete, in src/actions/branches.ts #7511

shipped production is serving it opened this has it
opened this

Intent: the ordering that keeps a mirror honest (docs/ORIGINS.md: the origin is truth) is proven, not only described. No test imports src/actions/branches.ts (207 lines) directly today.

Done:

  • [ ] A new test/branches-action.test.ts covers createBranch and deleteBranch. On a native repository the ref moves and the event is announced. On a mirrored repository whose origin refuses the push (a stubbed originPush, or a local bare origin with a hook that rejects), the local ref does not move and the refusal is returned in words. When the origin accepts, the local ref moves after it. A reader is refused with not_found.
  • [ ] If any of these fail, fix src/actions/branches.ts, and the pull says which behaviour was wrong.
  • [ ] No network: the origin is a local bare repository or a stub.

Files: a new test, and src/actions/branches.ts only if the test finds a fault.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs