From 6cf5742ac908561bf209b9bc68a5dbf025c5467d Mon Sep 17 00:00:00 2001 From: Drew Davis Date: Fri, 4 Dec 2026 08:59:47 -0500 Subject: [PATCH] test: Fix flaky dashboard E2E --- packages/app/tests/e2e/page-objects/DashboardPage.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/app/tests/e2e/page-objects/DashboardPage.ts b/packages/app/tests/e2e/page-objects/DashboardPage.ts index 2c11f324a..f0bf4d576 100644 --- a/packages/app/tests/e2e/page-objects/DashboardPage.ts +++ b/packages/app/tests/e2e/page-objects/DashboardPage.ts @@ -246,6 +246,10 @@ export class DashboardPage { async createNewDashboard() { await this.createDashboardButton.click(); await this.page.waitForURL(/\/dashboards\/.+/); + // The URL changes before the temporary dashboard page is swapped for the + // saved one. A rename typed in between lands on the temporary dashboard + // and is lost. The save button only exists on the temporary page. + await expect(this.createDashboardButton).toBeHidden({ timeout: 15000 }); } async changeGranularity(granularity: string) { @@ -564,6 +568,10 @@ export class DashboardPage { async openNewTileEditor() { await this.createDashboardButton.click(); await this.page.waitForURL(/\/dashboards\/.+/); + // The URL changes before the temporary dashboard page is swapped for the + // saved one. A rename typed in between lands on the temporary dashboard + // and is lost. The save button only exists on the temporary page. + await expect(this.createDashboardButton).toBeHidden({ timeout: 15000 }); await this.addDropdownButton.click(); await this.addTileMenuItem.click(); await expect(this.chartEditor.nameInput).toBeVisible();