From 41e771d9e16a83ffff479634e24f509ef97d015f Mon Sep 17 00:00:00 2001 From: Joel Jeremy Marquez Date: Sun, 13 Oct 2024 18:31:36 -0700 Subject: [PATCH] Assert data-navbar-state attribute --- packages/desktop-client/e2e/page-models/mobile-navigation.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/desktop-client/e2e/page-models/mobile-navigation.js b/packages/desktop-client/e2e/page-models/mobile-navigation.js index 258ec5a77d4..13901e799d9 100644 --- a/packages/desktop-client/e2e/page-models/mobile-navigation.js +++ b/packages/desktop-client/e2e/page-models/mobile-navigation.js @@ -1,4 +1,6 @@ import { MobileAccountPage } from './mobile-account-page'; +import { expect } from '@playwright/test'; + import { MobileAccountsPage } from './mobile-accounts-page'; import { MobileBudgetPage } from './mobile-budget-page'; import { MobileReportsPage } from './mobile-reports-page'; @@ -69,6 +71,8 @@ export class MobileNavigation { return false; } + await expect(this.navbar).toHaveAttribute('data-navbar-state'); + const dataNavbarState = await this.navbar.getAttribute('data-navbar-state'); return states.includes(dataNavbarState); }