Skip to content

Open-source AI teammates in Slack, Teams, Discord, Telegram and Mattermost. Self-host it, with any agent harness and any model.

Give the session-host tests longer than the waits inside them

Petr Bauch544f4c8630e2
diff --git a/console/packages/agent-providers/src/host/session-host.test.ts b/console/packages/agent-providers/src/host/session-host.test.ts
index 2b4f5c9c2..b9c0ef77c 100644
--- a/console/packages/agent-providers/src/host/session-host.test.ts
+++ b/console/packages/agent-providers/src/host/session-host.test.ts
@@ -16,6 +16,9 @@ import { HostedSession, type RoomReply, unpostedReply } from './session-host';
function waitFor<T>(check: () => T | Promise<T>): Promise<T> {
return vi.waitFor(check, { timeout: 10_000 });
}
+// A test makes several of those waits, so it gets longer than any one of them:
+// a slow machine then fails on what it waited for, not on the clock.
+vi.setConfig({ testTimeout: 30_000 });
const roots: string[] = [];
const hosts: HostedSession[] = [];
diff --git a/console/packages/agent-providers/src/host/shared-host.test.ts b/console/packages/agent-providers/src/host/shared-host.test.ts
index 82b323d1c..31b0b8655 100644
--- a/console/packages/agent-providers/src/host/shared-host.test.ts
+++ b/console/packages/agent-providers/src/host/shared-host.test.ts
@@ -18,6 +18,11 @@ import { connectParent, type ParentChannel } from './session-channel';
import { parkAfterMs, RESET_HOLD_MS, runSharedHost, sessionBusy } from './shared-host';
import { hostParked } from './shared-state';
+// Every step writes the session journal and flushes it to disk, which takes
+// Windows runners well over the default; a test waits up to 5 s for each, so it
+// gets longer than any one wait and fails on what it waited for, not the clock.
+vi.setConfig({ testTimeout: 30_000 });
+
const roots: string[] = [];
afterEach(async () => {
vi.unstubAllGlobals();