Fix global.setup.ts: tolerate post-login redirect away from wp-admin #2
Reference in New Issue
Block a user
Delete Branch "claude/setup-post-login-redirect-fix-20260514"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
/wp-admin/. On staging.peptiderepo.com, alogin_redirectfilter sends successful admin logins to the site homepage instead of wp-admin - so the assertion failed even on correct credentials. The login was actually succeeding (wordpress_logged_in_*cookie set, verified via direct curl probe) but Playwright treated the test as failed because the URL pattern didn't match.wp-login.php(i.e. login was accepted)/wp-admin/and assert we land there with#wpadminbarvisibleContext
This is the third bug in the smoke-gate chain. The first two were:
peptiderepo, should have beenadmin@peptiderepo.comWith those fixed, the post-login-redirect bug surfaced.
Test plan
Merge to main
Re-run failed
Deploy PRAutoBlogger to Hostingerjob on prautoblogger SHA1955f928Confirm setup project passes (not in the failure set anymore)
Confirm smoke gate passes and Deploy to Production promotes
CTO