From b3bb5d20f812718d3abf6fb9a31a3a55f9f8a171 Mon Sep 17 00:00:00 2001 From: Jacek Date: Fri, 6 Feb 2026 13:06:04 -0600 Subject: [PATCH 1/2] chore: placeholder for e2e test fixes From 3461dcd511064d43c7fc36d7ca48a863c0f67068 Mon Sep 17 00:00:00 2001 From: Jacek Date: Fri, 6 Feb 2026 14:12:08 -0600 Subject: [PATCH 2/2] fix(integration): increase setup timeout and parallelize HTTP servers - Increase setup timeout from 90s to 240s for CI variability - Start clerkJs and clerkUi HTTP servers in parallel via Promise.all - Cap http-server polling maxAttempts at 60 (was Infinity) - Add timing logs for HTTP server startup and app initialization --- integration/scripts/httpServer.ts | 2 +- integration/tests/global.setup.ts | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/integration/scripts/httpServer.ts b/integration/scripts/httpServer.ts index 7bcd8fb3abf..eb3121bba8b 100644 --- a/integration/scripts/httpServer.ts +++ b/integration/scripts/httpServer.ts @@ -38,7 +38,7 @@ const serveFromTempDir = async (config: HttpServerConfig): Promise<{ pid: number stderr: fs.openSync(stderrFilePath, 'a'), }); - await waitForServer(serverUrl, { log: console.log, maxAttempts: Infinity }); + await waitForServer(serverUrl, { log: console.log, maxAttempts: 60 }); console.log(`${config.name} is being served from`, serverUrl); return { pid: proc.pid, serverUrl }; diff --git a/integration/tests/global.setup.ts b/integration/tests/global.setup.ts index 377477b4979..c12ebf4d761 100644 --- a/integration/tests/global.setup.ts +++ b/integration/tests/global.setup.ts @@ -5,19 +5,22 @@ import { appConfigs } from '../presets'; import { fs, parseEnvOptions, startClerkJsHttpServer, startClerkUiHttpServer } from '../scripts'; setup('start long running apps', async () => { - setup.setTimeout(90_000); + setup.setTimeout(240_000); await fs.ensureDir(constants.TMP_DIR); - await startClerkJsHttpServer(); - await startClerkUiHttpServer(); + const httpServerStart = Date.now(); + await Promise.all([startClerkJsHttpServer(), startClerkUiHttpServer()]); + console.log(`HTTP servers started in ${Date.now() - httpServerStart}ms`); const { appIds } = parseEnvOptions(); if (appIds.length) { const apps = appConfigs.longRunningApps.getByPattern(appIds); // state cannot be shared using playwright, // so we save the state in a file using a strategy similar to `storageState` + const appStart = Date.now(); await Promise.all(apps.map(app => app.init())); + console.log(`Apps initialized in ${Date.now() - appStart}ms`); } else { // start a single app using the available env variables }