From 49c443a1b493afe8d26b09c8e76160d4a5a25ddc Mon Sep 17 00:00:00 2001 From: Codeman maintainer Date: Mon, 19 Oct 2026 05:18:36 +0200 Subject: [PATCH] fix(story-mode): the browser test's caption fit reads the Advanced level With the Director's cut as the default reading level, the story line the test lengthens is not shown, so its panel never grew and the check failed. The test now picks the Advanced level first, where that line is the caption. Co-Authored-By: Claude Opus 5.5 (1M context) --- test/story-mode.browser.test.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/story-mode.browser.test.ts b/test/story-mode.browser.test.ts index f9c7f82a..a6d682e1 100644 --- a/test/story-mode.browser.test.ts +++ b/test/story-mode.browser.test.ts @@ -169,6 +169,8 @@ describe('Story Mode in a real browser', () => { // A caption longer than the band above the art makes its panel taller, so it covers no art. const fit = await page.evaluate(async () => { const st = (window as any).app._story; + // The story line shows at the Advanced level (the Director's cut, the default, shows the tools). + (window as any).app._storySetLevel('advanced'); const rt = st.panels.find((p: { kind: string; splash: unknown }) => !p.splash && p.kind !== 'mission'); rt.capStory.textContent = 'Claude writes three files, runs the tests twice and saves the work. '.repeat(4); (window as any).app._storyFitCaption(rt);