app: fix Playwright E2E WebSocket errors on Node 20 + fix format

E2E helpers used DaemonClient without a webSocketFactory, which relies
on globalThis.WebSocket — unavailable in Node 20 (CI). Add a shared
node-ws-factory helper using the ws package (matching the CLI pattern)
and inject it in all three E2E connection helpers. Also fix a biome
formatting issue in the cli provider test.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Mohamed Boudra
2026-04-11 03:08:10 +00:00
parent 5b1c3dffba
commit 3fa43c865d
7 changed files with 98 additions and 34 deletions

View File

@@ -230,8 +230,7 @@ try {
assert(
ids.some(
(id) =>
(id.startsWith("openai/") || id.startsWith("openrouter/openai/")) &&
id.includes("codex"),
(id.startsWith("openai/") || id.startsWith("openrouter/openai/")) && id.includes("codex"),
),
"opencode output should include at least one codex-optimized OpenAI model",
);