Skip to content

Commit 9d708d5

Browse files
ryan-williamsclaude
andcommitted
Fix conflict test race condition with use-kbd hotkey handler
After use-kbd changes that enable hotkeys while modal is open (disabled only when editing), the test needs to wait for editing mode before pressing the conflicting key. Without this wait, the key press can trigger the existing action before React state propagates. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 3c38af3 commit 9d708d5

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

www/test/e2e/hotkey-editing.spec.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,10 @@ test.describe('Hotkey Editing', () => {
329329

330330
// Now assign 'x' to Temperature
331331
await leftKbd.click()
332+
333+
// Wait for editing mode before pressing key (prevents race with hotkey handler)
334+
await expect(leftKbd).toHaveClass(/editing/)
335+
332336
await page.keyboard.press('x')
333337

334338
// Wait for sequence timeout (1000ms) + buffer for conflict detection

0 commit comments

Comments
 (0)