From 98ee40037e75a2148f457b7d76d0da454834eec8 Mon Sep 17 00:00:00 2001 From: Euloge Date: Fri, 23 Oct 2026 08:00:48 +0200 Subject: [PATCH 1/2] ci(elos): run tests with concurrency 2 on CI Several test files start headless Chrome or an MCP server; full parallelism on small runners made Chrome miss its startup window. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/ci.yml | 3 ++- package.json | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1d23389..a2d395e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,4 +33,5 @@ jobs: - run: npm ci --no-audit --no-fund - run: npm run lint - run: npm run typecheck - - run: npm test + # Limited parallelism: several test files start headless Chrome or MCP servers. + - run: npm run test:ci diff --git a/package.json b/package.json index a6b08ba..433be53 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,7 @@ "mcp:elos": "node --experimental-strip-types --no-warnings --import ./tests/register-loader.mjs mcp/elos-server.ts", "typecheck": "tsc --noEmit", "test": "node --test --experimental-strip-types --import ./tests/register-loader.mjs \"tests/unit/**/*.test.ts\" \"tests/integration/**/*.test.ts\" \"tests/integration/**/*.test.cjs\"", + "test:ci": "node --test --test-concurrency=2 --experimental-strip-types --import ./tests/register-loader.mjs \"tests/unit/**/*.test.ts\" \"tests/integration/**/*.test.ts\" \"tests/integration/**/*.test.cjs\"", "validate:v1:local": "node scripts/validate-v1-local.mjs", "db:push": "prisma db push", "db:setup:local": "node scripts/setup-local-db.mjs", From 9e098ca16dcc248007e27c5a191762f2ac02e886 Mon Sep 17 00:00:00 2001 From: Euloge Date: Fri, 23 Oct 2026 08:03:44 +0200 Subject: [PATCH 2/2] test(elos): allow 180 s per CDP call in the browser harness The 10,000-event export/restore round-trip takes ~10 s locally but went past 60 s on CI runners. Co-Authored-By: Claude Opus 5.5 --- tests/integration/learning-history/browser-driver.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/integration/learning-history/browser-driver.mjs b/tests/integration/learning-history/browser-driver.mjs index cd0d8d8..13c8512 100644 --- a/tests/integration/learning-history/browser-driver.mjs +++ b/tests/integration/learning-history/browser-driver.mjs @@ -31,7 +31,7 @@ class DevTools { send(method, params = {}, sessionId = undefined) { const id = ++this.sequence; return new Promise((resolve, reject) => { - const timeout = setTimeout(() => { this.pending.delete(id); reject(new Error("CDP timeout: " + method)); }, 60000); + const timeout = setTimeout(() => { this.pending.delete(id); reject(new Error("CDP timeout: " + method)); }, 180000); // large 10k-event round-trips are slow on small CI runners this.pending.set(id, { resolve, reject, timeout }); this.socket.send(JSON.stringify({ id, method, params, ...(sessionId ? { sessionId } : {}) })); });