From cac988883148ecbd535b6cef9372f250c259f771 Mon Sep 17 00:00:00 2001 From: Garry Tan Date: Sat, 15 Aug 2026 11:11:09 -0700 Subject: [PATCH] test(browse): subprocess budget for the polyfill suite on Windows CI MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Every test here spawnSync's a node child; cold-start on the Windows runner (AV scan, first node.exe touch) blew bun's 5s default by 7ms on a 50ms sleep test. File-level 20s default — subprocess budget, not assertion looseness. --- browse/test/bun-polyfill.test.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/browse/test/bun-polyfill.test.ts b/browse/test/bun-polyfill.test.ts index 152ed3181..477f6ef27 100644 --- a/browse/test/bun-polyfill.test.ts +++ b/browse/test/bun-polyfill.test.ts @@ -1,6 +1,11 @@ -import { describe, test, expect, afterAll } from 'bun:test'; +import { describe, test, expect, afterAll, setDefaultTimeout } from 'bun:test'; import * as path from 'path'; +// Every test here spawnSync's a `node` child; Windows CI cold-start (AV scan, +// first-touch of node.exe) alone can blow bun's 5s default — observed 5,007ms +// on a 50ms sleep test. Subprocess budget, not assertion looseness. +setDefaultTimeout(20_000); + // Load the polyfill into a fresh object (don't clobber globalThis.Bun) const polyfillPath = path.resolve(import.meta.dir, '../src/bun-polyfill.cjs');