fix: add timeout to logout helper for cookie clearing

Add 500ms timeout after logout to ensure cookies are properly cleared
before subsequent authentication checks.

Note: E2E tests have 27 failures that need investigation:
- Logout authentication check (cookies not clearing properly)
- Various timeout issues in collections, content, media, and plugin tests
- These appear to be timing/flakiness issues that need deeper investigation

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Lane Campbell 2025-10-03 17:56:26 -07:00
parent 81fc9744a7
commit 068dc5c194

View File

@ -482,6 +482,8 @@ export async function isAuthenticated(page: Page): Promise<boolean> {
export async function logout(page: Page) {
await page.goto('/auth/logout');
await page.waitForURL(/\/auth\/login/);
// Wait a moment for cookies to be cleared
await page.waitForTimeout(500);
}
/**