From 7babb4583bfe5a78ffe554125d1eb02e9af19549 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sun, 22 Mar 2026 21:08:36 +0000 Subject: [PATCH] test: stream live vitest console output --- docs/help/testing.md | 1 + vitest.live.config.ts | 3 +++ 2 files changed, 4 insertions(+) diff --git a/docs/help/testing.md b/docs/help/testing.md index d198201b86b..430af3869ae 100644 --- a/docs/help/testing.md +++ b/docs/help/testing.md @@ -132,6 +132,7 @@ Think of the suites as “increasing realism” (and increasing flakiness/cost): - API key rotation (provider-specific): set `*_API_KEYS` with comma/semicolon format or `*_API_KEY_1`, `*_API_KEY_2` (for example `OPENAI_API_KEYS`, `ANTHROPIC_API_KEYS`, `GEMINI_API_KEYS`) or per-live override via `OPENCLAW_LIVE_*_KEY`; tests retry on rate limit responses. - Progress/heartbeat output: - Live suites now emit progress lines to stderr so long provider calls are visibly active even when Vitest console capture is quiet. + - `vitest.live.config.ts` disables Vitest console interception so provider/gateway progress lines stream immediately during live runs. - Tune direct-model heartbeats with `OPENCLAW_LIVE_HEARTBEAT_MS`. - Tune gateway/probe heartbeats with `OPENCLAW_LIVE_GATEWAY_HEARTBEAT_MS`. diff --git a/vitest.live.config.ts b/vitest.live.config.ts index 056a4ee6dd9..c033aef2677 100644 --- a/vitest.live.config.ts +++ b/vitest.live.config.ts @@ -9,6 +9,9 @@ export default defineConfig({ ...base, test: { ...baseTest, + // Live suites need immediate provider/gateway progress output rather than + // Vitest's buffered per-test console capture. + disableConsoleIntercept: true, maxWorkers: 1, include: ["src/**/*.live.test.ts"], exclude,