🐛 fix(vscode): 移交终审修正:schema 墓碑、顶层兜底、前置复查、分支保护、清单校验

Claude-Session: https://claude.ai/code/session_011cEyL6k351U2BzX1Qmygph
This commit is contained in:
cruldra committed 2026-08-26 17:09:39 +08:00
1 parent aa98dfb4e1
commit 0acfd04b54
10 files changed
+299 -220

No files matched your search

+23 -1
View File
@@ -87,7 +87,7 @@ describe('payloads', () => {
})
})
it('移交 UI patch 用 null 清字段并更新 assignees', () => {
expect(handoffStartedUiPatch(9, 'chw', 'me')).toEqual({
expect(handoffStartedUiPatch(9, 'chw', 'me', { keepWorktreePath: false })).toEqual({
handoffAttachmentId: '9',
handoffFrom: 'chw',
assignees: ['me'],
@@ -95,10 +95,32 @@ describe('payloads', () => {
implementSessionId: null,
reviewSessionId: null,
testSessionId: null,
profilePath: null,
brainstormProfilePath: null,
testProfilePath: null,
prDiffFile: null,
worktreePath: null,
worktreeExists: false,
})
})
it('移交 UI patch:keepWorktreePath=true 时省略 worktreePath / worktreeExists', () => {
const patch = handoffStartedUiPatch(9, 'chw', 'me', { keepWorktreePath: true })
expect(patch).not.toHaveProperty('worktreePath')
expect(patch).not.toHaveProperty('worktreeExists')
expect(patch).toEqual({
handoffAttachmentId: '9',
handoffFrom: 'chw',
assignees: ['me'],
sessionId: null,
implementSessionId: null,
reviewSessionId: null,
testSessionId: null,
profilePath: null,
brainstormProfilePath: null,
testProfilePath: null,
prDiffFile: null,
})
})
it('接管落盘:清两个共享字段,写本机 sid / profile / worktree', () => {
expect(handoffAcceptedStateExtra({
sessions: { implementSessionId: 'i', reviewSessionId: 'r' },