settings: Fix flaky test.

We wait for settings overlay to be fully visible before
running rest of the tests. Without this, tests were flaky due
to settings overlay not being present when running tests.
This commit is contained in:
Aman Agrawal 2024-11-19 15:49:41 +05:30
parent ca14366e38
commit 666c1e1d95
1 changed files with 2 additions and 0 deletions

View File

@ -30,6 +30,8 @@ async function open_settings(page: Page): Promise<void> {
page_url.includes("/#settings/"), page_url.includes("/#settings/"),
`Page url: ${page_url} does not contain /#settings/`, `Page url: ${page_url} does not contain /#settings/`,
); );
// Wait for settings overlay to open.
await page.waitForSelector("#settings_overlay_container", {visible: true});
} }
async function close_settings_and_date_picker(page: Page): Promise<void> { async function close_settings_and_date_picker(page: Page): Promise<void> {