From 6fb919ed9cb443a10d9a724f27e141601088d7f7 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 30 Oct 2026 23:16:55 +0000 Subject: [PATCH 1/2] test(signals): give the tree-shaking suite a 30 s timeout Every test in treeshake.test.ts runs a full Vite build of a fixture. The first one pays the bundler's cold start, and under the whole suite's load on CI it has run past vitest's 5 s default (5,295 ms on #4510, and on other PRs earlier today) without any assertion failing. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_015hPxMkC3jg3Uivh65gvaf2 --- packages/signals/tests/treeshake.test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/signals/tests/treeshake.test.ts b/packages/signals/tests/treeshake.test.ts index 9b7780b324..630bcefdd8 100644 --- a/packages/signals/tests/treeshake.test.ts +++ b/packages/signals/tests/treeshake.test.ts @@ -67,7 +67,10 @@ function retainedFrom(retained: string[], names: string[]): string[] { return names.filter(name => retained.some(id => id.includes(name))); } -describe("pay-for-use tree-shaking (#2883)", () => { +// Every test runs a full Vite build of a fixture, and the first one pays the +// bundler's cold start: under the whole suite's load on CI it ran past +// vitest's 5 s default (5,295 ms) while asserting nothing wrong. +describe("pay-for-use tree-shaking (#2883)", { timeout: 30_000 }, () => { it("core floor sheds every optional feature module", async () => { const { minifiedBytes, retained } = await bundleFixture( `export { createSignal, createMemo, createEffect, createRoot, flush } from "sigsrc";` From f44d5b46206335c11017a2e63fc15a10c2fe4630 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 30 Oct 2026 23:24:17 +0000 Subject: [PATCH 2/2] test(signals): widen the attribution self-time gap to 40 ms "measures self-time and aggregates costs by scope and root write" ranks a 10 ms memo above a cheap effect by wall-clock self-time. On this PR's CI run a scheduling pause inside the effect measured 17.9 ms against the memo's 10.1 ms. A 40 ms spin keeps the ranking meaningful under load. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_015hPxMkC3jg3Uivh65gvaf2 --- packages/signals/tests/attribution.test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/signals/tests/attribution.test.ts b/packages/signals/tests/attribution.test.ts index 84d1a3735d..c3edb78859 100644 --- a/packages/signals/tests/attribution.test.ts +++ b/packages/signals/tests/attribution.test.ts @@ -503,9 +503,12 @@ describe("why-did-this-run attribution", () => { while (performance.now() < end); }; const [n, setN] = createSignal(0, { name: "n" }); + // 40 ms, not 10: self-times are wall-clock, and on a loaded CI runner a + // scheduling pause inside the cheap effect measured 17.9 ms against the + // memo's 10.1 ms. The ranking asserted below needs the gap to be wide. const slow = createMemo( () => { - spin(10); + spin(40); return n(); }, { name: "slow-memo" }