From 045e1d4debe836731571c5e0c7b46b643587b4c2 Mon Sep 17 00:00:00 2001 From: Mohamed Boudra Date: Sat, 11 Apr 2026 07:38:37 +0000 Subject: [PATCH] fix(e2e): correct terminal tab testid and navigation URL in Playwright helper navigateToTerminal() used the bare workspace route instead of the URL with ?open=terminal: intent, and looked for testid "workspace-tab-terminal:" (colon) when the real tab key is "terminal_" (underscore). Both bugs prevented the terminal surface from ever appearing, causing terminal-performance tests to timeout. Co-Authored-By: Claude Opus 4.6 --- packages/app/e2e/helpers/terminal-perf.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/app/e2e/helpers/terminal-perf.ts b/packages/app/e2e/helpers/terminal-perf.ts index 60e164625..3cd340701 100644 --- a/packages/app/e2e/helpers/terminal-perf.ts +++ b/packages/app/e2e/helpers/terminal-perf.ts @@ -126,7 +126,7 @@ export async function navigateToTerminal( // Boot the app at the workspace route directly. // The fixtures.ts beforeEach addInitScript seeds localStorage on every navigation, // so the daemon registry is already configured when the app starts. - const workspaceRoute = buildHostWorkspaceRoute(getServerId(), input.cwd); + const workspaceRoute = buildTerminalWorkspaceUrl(input.cwd, input.terminalId); await page.goto(workspaceRoute); // Wait for daemon connection (sidebar shows host label) @@ -142,7 +142,7 @@ export async function navigateToTerminal( if (!surfaceVisible) { // Terminal tab might not be focused — look for it in the tab row and click it - const terminalTab = page.locator(`[data-testid="workspace-tab-terminal:${input.terminalId}"]`); + const terminalTab = page.locator(`[data-testid="workspace-tab-terminal_${input.terminalId}"]`); const tabExists = await terminalTab.isVisible({ timeout: 5_000 }).catch(() => false); if (tabExists) {