From 37e4f28e5721b12d608564fe7783119caa6e4409 Mon Sep 17 00:00:00 2001 From: Nawaz Dhandala Date: Fri, 3 Apr 2026 16:33:55 +0100 Subject: [PATCH] fix: update project dashboard URL regex to include optional home path --- E2E/Tests/Dashboard/CreateMonitor.spec.ts | 12 ++++++++---- E2E/Tests/Dashboard/CreateProject.spec.ts | 3 ++- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/E2E/Tests/Dashboard/CreateMonitor.spec.ts b/E2E/Tests/Dashboard/CreateMonitor.spec.ts index 826d178285..e227a966b7 100644 --- a/E2E/Tests/Dashboard/CreateMonitor.spec.ts +++ b/E2E/Tests/Dashboard/CreateMonitor.spec.ts @@ -3,7 +3,8 @@ import { Page, expect, test, Response, Locator } from "@playwright/test"; import URL from "Common/Types/API/URL"; import Faker from "Common/Utils/Faker"; -const projectDashboardUrlRegex: RegExp = /\/dashboard\/([a-f0-9-]+)(?:\/)?$/; +const projectDashboardUrlRegex: RegExp = + /\/dashboard\/([a-f0-9-]+)(?:\/home\/?)?$/; test.describe("Monitor Creation", () => { test("should be able to create a new monitor", async ({ @@ -134,9 +135,12 @@ test.describe("Monitor Creation", () => { break; } - await page.waitForURL(new RegExp(`/dashboard/${projectId}(?:/)?$`), { - timeout: 30000, - }); + await page.waitForURL( + new RegExp(`/dashboard/${projectId}(?:/home/?)?$`), + { + timeout: 30000, + }, + ); await page.waitForTimeout(1000); } } diff --git a/E2E/Tests/Dashboard/CreateProject.spec.ts b/E2E/Tests/Dashboard/CreateProject.spec.ts index 9cedcce308..47cc801f38 100644 --- a/E2E/Tests/Dashboard/CreateProject.spec.ts +++ b/E2E/Tests/Dashboard/CreateProject.spec.ts @@ -3,7 +3,8 @@ import { Page, expect, test, Response, Locator } from "@playwright/test"; import URL from "Common/Types/API/URL"; import Faker from "Common/Utils/Faker"; -const projectDashboardUrlRegex: RegExp = /\/dashboard\/([a-f0-9-]+)(?:\/)?$/; +const projectDashboardUrlRegex: RegExp = + /\/dashboard\/([a-f0-9-]+)(?:\/home\/?)?$/; test.describe("Project Creation", () => { test("should be able to create a new project", async ({