diff --git a/src/e2e/global-setup.ts b/src/e2e/global-setup.ts index 827764444f9..c25bfe9c9ad 100644 --- a/src/e2e/global-setup.ts +++ b/src/e2e/global-setup.ts @@ -25,8 +25,9 @@ async function globalSetup(config: FullConfig) { // commenting out as this its not needed for now // // go to sign up page - await page.goto(process.env.E2E_TEST_BASE_URL as string); - await page.waitForLoadState("domcontentloaded"); + await page.goto(process.env.E2E_TEST_BASE_URL as string, { + waitUntil: "domcontentloaded", + }); const landingPage = new LandingPage(page); await landingPage.goToSignIn(); diff --git a/src/e2e/utils/helpers.ts b/src/e2e/utils/helpers.ts index 297d8f3459c..e6963198930 100644 --- a/src/e2e/utils/helpers.ts +++ b/src/e2e/utils/helpers.ts @@ -177,7 +177,9 @@ export const clickOnATagCheckDomain = async ( const href = await aTag.getAttribute("href"); if (href === null) return false; - await page.goto(href); + await page.goto(href, { + waitUntil: "commit", + }); const currentUrl = new URL(page.url()); const perceivedHost = currentUrl.hostname; const perceivedPath = currentUrl.pathname;