Skip to content

Fix flaky Playwright e2e coverage - #950

Merged
cursor[bot] merged 1 commit into
mainfrom
cursor/fix-flaky-e2e-2490
Jul 25, 2026
Merged

cursor[bot] merged 1 commit into
mainfrom
cursor/fix-flaky-e2e-2490

Conversation

@kentcdodds

@kentcdodds kentcdodds commented Jul 25, 2026 •

Copy link
Copy Markdown
Member

Summary

CI history showed recurring Playwright flakes on scroll-restore-slow-frame (hard fail + flaky retries, scroll stuck at the detail offset) and intermittent timeouts in the separate passkey+2FA journey. This PR trims low-signal coverage and hardens the remaining passkey happy path.

  • Deleted e2e/scroll-restore-slow-frame.spec.ts — edge-case regression that was itself flaky; happy-path scroll restoration remains in ssr-hydration.spec.ts.
  • Merged passkey register / MFA-skip / delete into one lifecycle test; navigate via localhost with domcontentloaded so CI load does not stall on full load.
  • Deleted empty account jobs/memories heading smokes that only asserted list chrome.

Local playwright test: 20 passed.

System recap — composes existing primitives (low risk)

Mode: recap · Base: main · Head: cursor/fix-flaky-e2e-2490

Classification: composes — Playwright suite only; no product primitives added or changed.

Primitives touched

None. Classifier unmatched paths are all under e2e/.

System map

Test-only change: remove flaky/low-signal Playwright cases and harden the passkey lifecycle journey. No runtime wiring.

Legend: green = composes (wiring only) · amber = extended by this PR · red = new primitive · gray = context (unchanged, included only when an edge crosses it).

flowchart LR
	playwright["Playwright e2e suite"]:::touched
	passkeys["passkeys + 2FA UI journey"]:::touched
	playwright -->|"merged lifecycle + localhost nav"| passkeys
	classDef touched fill:#1a7f37,color:#fff
	classDef extended fill:#9a6700,color:#fff
	classDef added fill:#cf222e,color:#fff
	classDef untouched fill:#57606a,color:#fff
Loading

Before / after

Before After
Separate slow-frame scroll e2e (flaky) Removed; SSR hydration still covers restore
Passkey lifecycle + separate 2FA-skip test One hardened lifecycle journey
Jobs/memories empty-heading smokes Removed; detail URL journeys kept
Open in Web Open in Cursor 

Summary by CodeRabbit

  • Tests
    • Updated passkey end-to-end coverage for more reliable localhost navigation and two-factor authentication flows.
    • Retained coverage for passkey sign-in when two-factor authentication is enabled.
    • Removed redundant account jobs and memories empty-state checks.
    • Removed the slow-frame scroll restoration regression test.

Remove the repeatedly flaky slow-frame scroll-restoration regression (happy-path
restoration remains in ssr-hydration), fold passkey MFA-skip into the lifecycle
journey with localhost/domcontentloaded navigation hardening, and drop empty
account list heading smokes that only asserted page chrome.
@coderabbitai

coderabbitai Bot commented Jul 25, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 0b6ac25b-3d12-411f-8858-bf807872ac28

📥 Commits

Reviewing files that changed from the base of the PR and between f849df4 and c873523.

📒 Files selected for processing (4)
  • e2e/account-jobs.spec.ts
  • e2e/account-memories.spec.ts
  • e2e/passkeys.spec.ts
  • e2e/scroll-restore-slow-frame.spec.ts
💤 Files with no reviewable changes (3)
  • e2e/scroll-restore-slow-frame.spec.ts
  • e2e/account-jobs.spec.ts
  • e2e/account-memories.spec.ts

📝 Walkthrough

Walkthrough

The PR standardizes localhost navigation in the passkey lifecycle test and updates its description for TOTP skipping. It also removes account jobs, account memories, and slow-frame scroll-restoration end-to-end tests.

Changes

End-to-end test updates

Layer / File(s) Summary
Passkey lifecycle navigation
e2e/passkeys.spec.ts
Adds gotoLocalhost, applies it across the passkey, two-factor, login, and account flows, and renames the lifecycle test to describe skipping TOTP when 2FA is enabled.
E2E coverage cleanup
e2e/account-jobs.spec.ts, e2e/account-memories.spec.ts, e2e/scroll-restore-slow-frame.spec.ts
Removes account empty-state checks and the slow-frame scroll-restoration regression test.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the PR’s main goal of fixing flaky Playwright e2e coverage.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cursor/fix-flaky-e2e-2490

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cursor
cursor Bot marked this pull request as ready for review July 25, 2026 22:22
@github-actions

Copy link
Copy Markdown
Contributor

🔎 Preview deployed: https://kody-pr-950.kody-a99.workers.dev

Worker: kody-pr-950
D1: kody-pr-950-db
KV: kody-pr-950-oauth-kv

Mocks:

@cursor
cursor Bot merged commit 475780d into main Jul 25, 2026
16 checks passed
@cursor
cursor Bot deleted the cursor/fix-flaky-e2e-2490 branch July 25, 2026 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants