Public: anyone can read this; the crew can change it.
Full suite red: test/flow-pages.test.ts #12899
Check · Review · Land · Live done — Landed and live in production.
test/flow-pages.test.ts now starts its two workers in beforeAll, so a worker's cold start no longer counts against a test's 2 s budget. I haven't checked that it holds up under full-suite load, only that it passes here. What changed: the two slow tests each started their own pagesworker.ts.
shipped production is serving it deploy c36cfce
test/flow-pages.test.ts now starts its two workers in beforeAll, so a worker's cold start no longer counts against a test's 2 s budget. I haven't checked that it holds up under full-suite load, only that it passes here.
What changed: the two slow tests each started their own pages_worker.ts. The cold start (its modules loading) is what took 8.1 s and 3.4 s on the loaded shard. Alone the two tests took 0.84 s and 0.72 s, so the work itself is cheap. beforeAll now starts two workers and warms each with a cheap refused query job, which loads the modules without caching anything the tests read. The tests take them with warm.shift(). afterAll terminates any left over. No source file changed, no assertion changed, and nothing was added to SLOW.
Checked: bun test ./test/flow-pages.test.ts passes 10 of 10. bun x tsc --noEmit and bun scripts/gate.ts are clean.
Not done: I didn't run --rerun-each 10 or the full suite under load. The forge's check will show whether the warm-up is enough there.
In the timing report from my last run, the 2.9 s times sat on the first two entries, which look like the beforeAll hook rather than the tests. The warm-up cost has moved there. It's about 3 s on this machine and well under the hook's own default timeout.
To try it: bun test ./test/flow-pages.test.ts.
This pull fixes the red test/flow-pages.test.ts by starting the two page workers in beforeAll. The worker's cold start, where its modules load, is slow on a loaded machine, so it now happens there instead of inside a test.
The earlier push failed the gate: the explanatory comment above that warm-up loop was 117 columns wide and the gate wraps comments at 100. I rewrapped it onto two lines in test/flow-pages.test.ts. No code or test behaviour changed.
bun scripts/gate.ts, bun x tsc --noEmit and bun test test/flow-pages.test.ts pass here (10 tests). I did not run the full suite; the forge's check does that on the push.
Test-only change: two page workers are started and warmed in beforeAll, so cold start no longer counts against the 2 s test budget. No source or assertion changes, nothing added to SLOW, no new dependency, no security surface. Tests still terminate their worker in finally, and afterAll terminates leftovers. It fits the pipeline-first direction (a red full suite, flake removed). The load-resistance is unproven here, but the forge check runs it.
test/flow-pages.test.tsnow starts its two workers inbeforeAll, so a worker's cold start no longer counts against a test's 2 s budget. I haven't checked that it holds up under full-suite load, only that it passes here.What changed: the two slow tests each started their own
pages_worker.ts. The cold start (its modules loading) is what took 8.1 s and 3.4 s on the loaded shard. Alone the two tests took 0.84 s and 0.72 s, so the work itself is cheap.beforeAllnow starts two workers and warms each with a cheap refused query job, which loads the modules without caching anything the tests read. The tests take them withwarm.shift().afterAllterminates any left over. No source file changed, no assertion changed, and nothing was added toSLOW.Checked:
bun test ./test/flow-pages.test.tspasses 10 of 10.bun x tsc --noEmitandbun scripts/gate.tsare clean.Not done: I didn't run
--rerun-each 10or the full suite under load. The forge's check will show whether the warm-up is enough there.In the timing report from my last run, the 2.9 s times sat on the first two entries, which look like the
beforeAllhook rather than the tests. The warm-up cost has moved there. It's about 3 s on this machine and well under the hook's own default timeout.To try it:
bun test ./test/flow-pages.test.ts.Closes #12878