test(e2e): allow normalized route query state

This commit is contained in:
0xJacky
2026-08-16 22:57:49 +08:00
parent 8a9433474c
commit efd6b715df

View File

@@ -20,7 +20,7 @@ export async function gotoRoute(page: Page, route: string) {
expect(response.ok(), `Navigation to ${url} returned ${response.status()}`).toBe(true)
}
await expect.poll(() => new URL(page.url()).pathname).toBe('/')
await expect.poll(() => new URL(page.url()).hash).toBe(url.slice(1))
await expect.poll(() => new URL(page.url()).hash.split('?')[0]).toBe(url.slice(1))
await expect(page).not.toHaveURL(/\/login(?:\?|$)/)
}