From 76e87ffb2f71d4386d4076ce295dbaa0eadb88e5 Mon Sep 17 00:00:00 2001 From: garrytan Date: Mon, 26 Oct 2026 14:25:53 +0000 Subject: [PATCH] test(docsync): fixtureDocs installs the generated sections/preamble.md (hunk taken from #3472) A generated skill that loads the shared preamble names sections/preamble.md as a required asset before skill start, and a spawned document-release child blocks on its absence, so docsync-spawned stayed red on every #3434 screen. fixtureDocs now copies that file when the generated skill has it. This single hunk is taken unchanged from gstack#3472 (head 2e3f7ba1, GSTA-107), which trains ahead of #3434, so the train merge sees identical lines. Nothing else from #3472 is included. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --- test/helpers/docsync-fixture.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/test/helpers/docsync-fixture.ts b/test/helpers/docsync-fixture.ts index fe653ccb7..cce80062a 100644 --- a/test/helpers/docsync-fixture.ts +++ b/test/helpers/docsync-fixture.ts @@ -60,9 +60,13 @@ export function fixtureDocs(scenario: DocsScenario, generatedRoot = process.env. write('personal-note.txt', 'Unrelated user content: KEEP THIS EXACTLY.\n'); for (const skill of ['document-release', 'ship']) { fs.mkdirSync(path.join(skills, skill, 'sections'), { recursive: true }); - for (const relative of skill === 'ship' + const required = skill === 'ship' ? ['SKILL.md', 'sections/documentation.md', 'sections/pr-body.md'] - : ['SKILL.md', 'sections/audit-scope.md', 'sections/release-body.md']) { + : ['SKILL.md', 'sections/audit-scope.md', 'sections/release-body.md']; + // A generated skill that loads a shared preamble names sections/preamble.md as a + // required asset before skill start; a spawned child blocks on its absence. + const preamble = fs.existsSync(path.join(generatedRoot, skill, 'sections/preamble.md')) ? ['sections/preamble.md'] : []; + for (const relative of [...required, ...preamble]) { const source = path.join(generatedRoot, skill, relative); if (!fs.existsSync(source)) throw new Error(`Generate the changed skill before live evaluation: ${source}`); fs.copyFileSync(source, path.join(skills, skill, relative));