From d9cfa873ecd4b582192f297c19addd8b98542fc2 Mon Sep 17 00:00:00 2001 From: garrytan Date: Sat, 17 Oct 2026 19:32:35 +0000 Subject: [PATCH] test(review-army): size the nested bun test budgets for windows-latest (W3-15) windows-free-tests run 39053431430 (shard 5): the nested bun test exited 1 in 5.58 s because Bun's default 5 s hook timeout fired on the real Red Team beforeAll (8 git spawns plus skill-section copies). Both nested argvs pass --timeout 30000, which raises only the nested default; the registrations under test keep their explicit timeouts. Spawn timeouts move from 8 s to 40 s and outer test timeouts to 45 s, including the consensus test that had none. With a 6 s beforeAll injected, the lifecycle still matches; the old argv reproduces the Windows hook timeout. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --- test/review-army-budget.test.ts | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/test/review-army-budget.test.ts b/test/review-army-budget.test.ts index b5458f5c7..1083e748e 100644 --- a/test/review-army-budget.test.ts +++ b/test/review-army-budget.test.ts @@ -54,8 +54,11 @@ new Function('describe', 'test', 'expect', 'beforeAll', 'afterAll', ); afterAll(() => console.log('CONSENSUS_LIFECYCLE=' + JSON.stringify({ attempts, records, registrations, captureOptions, runIds }))); `); - const child = Bun.spawnSync([process.execPath, 'test', '--retry', '1', script], { - cwd: dir, stdout: 'pipe', stderr: 'pipe', timeout: 8_000, + // windows-free-tests 39053431430: the real describe's git-heavy beforeAll outlived Bun's 5 s default hook + // timeout on windows-latest. --timeout raises only the nested default; the registrations under test keep + // their explicit timeouts. + const child = Bun.spawnSync([process.execPath, 'test', '--retry', '1', '--timeout', '30000', script], { + cwd: dir, stdout: 'pipe', stderr: 'pipe', timeout: 40_000, }); const output = child.stdout.toString() + child.stderr.toString(); expect(child.exitCode, output).toBe(0); @@ -73,7 +76,7 @@ afterAll(() => console.log('CONSENSUS_LIFECYCLE=' + JSON.stringify({ attempts, r } finally { fs.rmSync(dir, { recursive: true, force: true }); } -}); +}, 45_000); for (const validReport of [true, false]) { test(`red-team retries only after cancellation and recording, and preserves report validation (${validReport})`, () => { @@ -134,8 +137,8 @@ afterAll(async () => { fixturesRemoved: fixturePaths.every(p => !fs.existsSync(p)) })); }); `); - const child = Bun.spawnSync([process.execPath, 'test', '--retry', '1', script], { - cwd: dir, stdout: 'pipe', stderr: 'pipe', timeout: 8_000, + const child = Bun.spawnSync([process.execPath, 'test', '--retry', '1', '--timeout', '30000', script], { + cwd: dir, stdout: 'pipe', stderr: 'pipe', timeout: 40_000, env: { ...process.env, EVALS: '', EVALS_MODEL: 'fixture-model' }, }); const output = child.stdout.toString() + child.stderr.toString(); @@ -157,7 +160,7 @@ afterAll(async () => { } finally { fs.rmSync(dir, { recursive: true, force: true }); } - }, 10_000); + }, 45_000); } // review-army-simplification headroom (#3153): the session's premise matches its staged