Skip to content

test(desktop): stabilize keyboard community reorder - #4652

Open
kiranmagic7 wants to merge 1 commit into
block:mainfrom
kiranmagic7:fix/community-rail-keyboard-reorder-flake
Open

test(desktop): stabilize keyboard community reorder#4652
kiranmagic7 wants to merge 1 commit into
block:mainfrom
kiranmagic7:fix/community-rail-keyboard-reorder-flake

Conversation

@kiranmagic7

Copy link
Copy Markdown
Contributor

Summary

Synchronize the keyboard-reorder test with dnd-kit's observable drag lifecycle. KeyboardSensor attaches its document keydown listener on the next timer tick, so the test could send ArrowUp before the sensor was ready. The drop could also race the updated collision target and preserve the original order.

The test now waits for pickup and for B to move above A before dropping. Product behavior is unchanged.

Related issue

Fixes #4530.

Testing

  • On unmodified upstream/main, the issue reproduction produced 6 first-attempt failures out of 20; all retries passed.

  • With this patch, the same command passed 20/20 without retries:

    cd desktop
    CI=1 pnpm exec playwright test tests/e2e/community-rail.spec.ts \
      --project=smoke \
      --grep 'keyboard reorder' \
      --repeat-each=20 \
      --reporter=list
  • just ci

  • Screenshots are not applicable; this is a test-only change.

Signed-off-by: kiranmagic7 <262980978+kiranmagic7@users.noreply.github.com>
@kiranmagic7
kiranmagic7 requested a review from a team as a code owner August 4, 2026 03:13
@kiranmagic7

Copy link
Copy Markdown
Contributor Author

Re-checked the current head 09bb0cbbe82f98958b14723c24cf20cf816aa4d1: the branch is still mergeable, and DCO, Semgrep, and zizmor are green. The Buzz CI and Desktop Release Candidate runs are still waiting on fork-workflow approval with zero jobs, so there is no failing hosted log for me to fix.

Review focus is the one-file Playwright synchronization in desktop/tests/e2e/community-rail.spec.ts; the PR body has the 20/20 repro and verification against #4530.

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.

test(desktop): keyboard community reorder flakes before retry

1 participant