From f32fede855a5bc5bb4525dc0753e21855ab1d37a Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 18 Sep 2026 09:22:32 +0000 Subject: [PATCH] Wait for all six players in the colour-map fixture test tests/player-colour-map.spec.js waited for exactly five ready players on the painting fixture, the count from before #334 and #335 grew the page: it now carries six live players (the seventh table is the deliberately bad one, which never becomes an instance). Five is a count the page only passes through, and once two players finish in the same frame it is never observed, so the wait times out. main's own run on the #335 merge fails on this test. Six is what tests/player-painting.spec.js already waits for. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01CrHtVussSR8ZxsxisaepJM --- tests/player-colour-map.spec.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/player-colour-map.spec.js b/tests/player-colour-map.spec.js index 298681c..a1cc0df 100644 --- a/tests/player-colour-map.spec.js +++ b/tests/player-colour-map.spec.js @@ -141,7 +141,11 @@ test.describe('the colour-map radio row', () => { test('the colour-map config row opens a table in grey or inferno, and the row shows it', async ({ page }) => { await page.goto(PAINTING_PAGE) - await page.waitForFunction(() => window.GramFrame.__test__getInstances().filter(i => i.state.player.ready).length === 5) + // Six players, as tests/player-painting.spec.js waits for: the fixture's + // seventh table is the deliberately bad one, which never becomes an + // instance. Waiting for a count the page only passes through (it was 5, + // from before the fixture grew) is a race the page can skip in one frame. + await page.waitForFunction(() => window.GramFrame.__test__getInstances().filter(i => i.state.player.ready).length === 6) const plain = await samplePixels(page, 0) const grey = await samplePixels(page, 2)