diff --git a/test/end-to-end/thirdparty.test.js b/test/end-to-end/thirdparty.test.js index 076bb2869..dac9a98b1 100644 --- a/test/end-to-end/thirdparty.test.js +++ b/test/end-to-end/thirdparty.test.js @@ -436,7 +436,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); @@ -466,7 +466,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); @@ -496,7 +496,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); @@ -526,7 +526,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); @@ -556,7 +556,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); @@ -586,7 +586,7 @@ export function getThirdPartyTestCases({ authRecipe, rid, signInUpPageLoadLogs, ...signInUpPageLoadLogs, ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert(search.endsWith("error=signin")); }); }); diff --git a/test/end-to-end/thirdpartyemailpassword.test.js b/test/end-to-end/thirdpartyemailpassword.test.js index 69f9f17eb..ae102d88d 100644 --- a/test/end-to-end/thirdpartyemailpassword.test.js +++ b/test/end-to-end/thirdpartyemailpassword.test.js @@ -408,7 +408,7 @@ describe("SuperTokens Third Party Email Password", function () { "ST_LOGS SUPERTOKENS GET_REDIRECTION_URL TO_AUTH", ]); await waitForUrl(page, "/auth/"); - const search = page.evaluate(() => window.location.search); + const search = await page.evaluate(() => window.location.search); assert.deepStrictEqual(search, "?error=signin"); }); });