[Bug]: flakey test on FocusScope.test
epr3 opened this issue · comments
Environment
Environment: GitHub Actions
Node version: 16.0.0
Package manager: pnpm@8.15.4
Radix Vue version: 1.8.1
Browser: JSDOM
Link to minimal reproduction
https://github.com/radix-vue/radix-vue/actions/runs/9234626056/job/25408556669
Steps to reproduce
- Run tests
- Observe error
Describe the bug
TypeError: Failed to execute 'dispatchEvent' on 'EventTarget': parameter 1 is not of type 'Event'.
This error originated in "src/FocusScope/FocusScope.test.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
This error was caught after test environment was torn down. Make sure to cancel any running tasks before test finishes:
- cancel timeouts using clearTimeout and clearInterval
- wait for promises to resolve using the await keyword
Expected behavior
Tests should pass
Context & Screenshots (if applicable)
No response
@zernonia I'll take a look, but it'll take some time because I can't reliably reproduce the issue. Will keep you posted 👍