mirror of
https://github.com/stablyai/orca.git
synced 2026-11-02 01:57:57 +00:00
fix(worktree): track explicit remote-only branch (#31645)
* fix(worktree): track explicit remote branch * test(worktree): cover remote branch path retry * fix(worktree): resolve cached remote branches canonically * fix(git): retain commit validation in bounded ref probes * fix(worktree): preserve selected remote identity during creation * test(worktree): count cached resolver Git work during path retries * Fix branch intent state in composer source fixture * Make Git and daemon regression fixtures portable * Use the selected base for existing branch creation --------- Co-authored-by: Brennan Benson <79079362+brennanb2025@users.noreply.github.com>
This commit is contained in:
@@ -78,6 +78,9 @@ it('tracks the remote branch it was created from, and nothing else', async () =>
|
||||
const fixPath = join(root, 'fix')
|
||||
await addWorktree(repo, fixPath, 'alex/fix', 'origin/alex/fix')
|
||||
expect(await upstreamOf(fixPath, 'alex/fix')).toBe('origin/alex/fix')
|
||||
const ref = 'refs/remotes/origin/alex/fix'
|
||||
expect(await git(fixPath, 'config', '--get', 'branch.alex/fix.base')).toBe(ref)
|
||||
expect(await git(fixPath, 'config', '--get', 'push.autoSetupRemote')).toBe('true')
|
||||
expect(await git(fixPath, 'rev-parse', 'HEAD')).toBe(
|
||||
await git(repo, 'rev-parse', 'refs/remotes/origin/alex/fix')
|
||||
)
|
||||
@@ -112,4 +115,10 @@ it('tracks the remote branch when a prepared checkout finalizes the create', asy
|
||||
prepared.lockReason
|
||||
)
|
||||
expect(await upstreamOf(fixPath, 'alex/fix')).toBe('origin/alex/fix')
|
||||
const ref = 'refs/remotes/origin/alex/fix'
|
||||
expect(await git(fixPath, 'config', '--get', 'branch.alex/fix.base')).toBe(ref)
|
||||
expect(await git(fixPath, 'config', '--get', 'push.autoSetupRemote')).toBe('true')
|
||||
expect(await git(fixPath, 'rev-parse', 'HEAD')).toBe(
|
||||
await git(repo, 'rev-parse', 'refs/remotes/origin/alex/fix')
|
||||
)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user