-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Description
Provide a general summary of the issue here
The selectOption method of a test User for the menu ARIA pattern call jest.runAllTimers() when it might not be installed in the test environment (if setup with vitest for example)
🤔 Expected Behavior?
@react-aria/test-utils should work with jest or vitest. I assume that because of the way the test User is setup and can be passed a method for advanceTimer
😯 Current Behavior
Test using the menu ARIA pattern will fail if trying to select an option or open a submenu
💁 Possible Solution
the runAllTimers method could be injected in addition of advanceTimer
🔦 Context
Trying the alpha version of @react-aria/test-utils to replace some homemade utils to interact with react app using RAC components
🖥️ Steps to Reproduce
- Open this code sandbox
- Run the test script
Version
@react-aria/test-utils 1.0.0-alpha.4
What browsers are you seeing the problem on?
Other
If other, please specify.
Chromuim from playwright
What operating system are you using?
macOS
🧢 Your Company/Team
No response
🕷 Tracking Issue
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Type
Projects
Status
✅ Done