Skip to content

A local-first multi-agent app development platform, built on PenguinHarness

fix(web): 满载跑全量测试时,几处扫描源码的用例不再被 5 秒超时判红

lmlihengff79b99a6883
diff --git a/packages/web/vitest.config.ts b/packages/web/vitest.config.ts
index b662d634..f2958a09 100644
--- a/packages/web/vitest.config.ts
+++ b/packages/web/vitest.config.ts
@@ -19,6 +19,12 @@ export default defineConfig({
include: ["test/**/*.test.ts"],
// Every vi.stubGlobal (fetch, localStorage, …) is undone before the next test starts.
unstubGlobals: true,
+ // Several suites here scan every source file of the package with the TypeScript compiler, and
+ // dock-state's beforeAll imports a whole module graph: on an idle machine those take 2–4s, so
+ // the 5s default leaves no headroom and the suite went red on a loaded box while the same
+ // files passed alone. The timeouts only bound the wait; the assertions are unchanged.
+ testTimeout: 30_000,
+ hookTimeout: 30_000,
// `vitest run --coverage`: branch and line coverage of the app's own source.
coverage: { provider: "v8", include: ["src/**"] },
},