Skip to content

Scheduling infrastructure for absolutely everyone.

fix: wait for networkidle in locale e2e tests to avoid hydration race condition (#28341)

Romit0f0a6382473e
diff --git a/apps/web/playwright/locale.e2e.ts b/apps/web/playwright/locale.e2e.ts
index 2aa427ae6f3..2b9c1836de0 100644
--- a/apps/web/playwright/locale.e2e.ts
+++ b/apps/web/playwright/locale.e2e.ts
@@ -402,7 +402,7 @@ test.describe("authorized user sees changed translations (de->ar)", async () =>
await test.step("should change the language and show Arabic translations", async () => {
await page.goto("/settings/my-account/general");
- await page.waitForLoadState("domcontentloaded");
+ await page.waitForLoadState("networkidle");
await page.getByTestId("locale-select").click();
await page.getByTestId("select-option-ar").click();
@@ -462,7 +462,7 @@ test.describe("authorized user sees changed translations (de->pt-BR) [locale1]",
await test.step("should change the language and show Brazil-Portuguese translations", async () => {
await page.goto("/settings/my-account/general");
- await page.waitForLoadState("domcontentloaded");
+ await page.waitForLoadState("networkidle");
await page.getByTestId("locale-select").click();
await page.getByTestId("select-option-pt-BR").click();