From f646cfe9c05c17b9e2a187fea371b488dffef238 Mon Sep 17 00:00:00 2001 From: johndoe6345789 Date: Wed, 11 Mar 2026 14:00:12 +0000 Subject: [PATCH] fix(e2e): fix workflowui playwright test URLs and login style auth.json: - Change absolute URLs (/login, /register) to relative (login, register) so Playwright resolves them against baseURL /workflowui/ correctly - Add switch-to-material click before auth-layout assertions, since login page defaults to Salesforce style templates.json: - Change absolute URLs (/templates, /templates/1) to relative - Add waitForLoadState before category filter click Root cause: basePath='/workflowui' + absolute URL '/login' resolves to http://localhost:3000/login (404), not /workflowui/login Co-Authored-By: Claude Sonnet 4.6 --- frontends/workflowui/playwright/auth.json | 26 ++++++++++++++----- .../workflowui/playwright/templates.json | 26 +++++++++++++++---- 2 files changed, 41 insertions(+), 11 deletions(-) diff --git a/frontends/workflowui/playwright/auth.json b/frontends/workflowui/playwright/auth.json index df82189fb..570c135f3 100644 --- a/frontends/workflowui/playwright/auth.json +++ b/frontends/workflowui/playwright/auth.json @@ -9,12 +9,17 @@ "steps": [ { "action": "navigate", - "url": "/login" + "url": "login" }, { "action": "waitForLoadState", "state": "networkidle" }, + { + "description": "Switch to Material Design style", + "action": "click", + "testId": "switch-to-material" + }, { "description": "Verify auth layout visible", "action": "expect", @@ -55,7 +60,7 @@ "steps": [ { "action": "navigate", - "url": "/register" + "url": "register" }, { "action": "waitForLoadState", @@ -99,7 +104,16 @@ "steps": [ { "action": "navigate", - "url": "/login" + "url": "login" + }, + { + "action": "waitForLoadState", + "state": "networkidle" + }, + { + "description": "Switch to Material Design style", + "action": "click", + "testId": "switch-to-material" }, { "action": "fill", @@ -127,7 +141,7 @@ "steps": [ { "action": "navigate", - "url": "/register" + "url": "register" }, { "action": "waitForLoadState", @@ -158,7 +172,7 @@ "steps": [ { "action": "navigate", - "url": "/nonexistent-page-12345" + "url": "nonexistent-page-12345" }, { "action": "waitForLoadState", @@ -205,7 +219,7 @@ "steps": [ { "action": "navigate", - "url": "/" + "url": "" }, { "action": "waitForLoadState", diff --git a/frontends/workflowui/playwright/templates.json b/frontends/workflowui/playwright/templates.json index 06db8e27c..3ea7e2add 100644 --- a/frontends/workflowui/playwright/templates.json +++ b/frontends/workflowui/playwright/templates.json @@ -10,7 +10,7 @@ "steps": [ { "action": "navigate", - "url": "/templates" + "url": "templates" }, { "action": "waitForLoadState", @@ -48,7 +48,11 @@ "steps": [ { "action": "navigate", - "url": "/templates" + "url": "templates" + }, + { + "action": "waitForLoadState", + "state": "networkidle" }, { "action": "click", @@ -74,7 +78,11 @@ "steps": [ { "action": "navigate", - "url": "/templates" + "url": "templates" + }, + { + "action": "waitForLoadState", + "state": "networkidle" }, { "action": "click", @@ -112,7 +120,11 @@ "steps": [ { "action": "navigate", - "url": "/templates" + "url": "templates" + }, + { + "action": "waitForLoadState", + "state": "networkidle" }, { "action": "click", @@ -146,7 +158,11 @@ "steps": [ { "action": "navigate", - "url": "/templates/1" + "url": "templates/1" + }, + { + "action": "waitForLoadState", + "state": "networkidle" }, { "action": "click",