Replies: 3 comments 1 reply
-
I am also interested in this |
Beta Was this translation helpful? Give feedback.
-
Reading this https://testing-library.com/docs/guide-events/#interactions-vs-events, It doesn't look like Nonetheless, if you want |
Beta Was this translation helpful? Give feedback.
-
We plan to implement the We do not plan to implement low-level Note that you can still access your provider's API with commands. |
Beta Was this translation helpful? Give feedback.
-
I would like to request similar events that the Storybook tests provide. In Storybook tests you can import
fireEvent
, which containsmouseDown
,mouseMove
andmouseUp
functions. Here is the documentation about using thefireEvent
. It seems to be using the Testing library under the hood: How does component testing in Storybook work?.My use case for this is simple. I want to be able to test that our resize handle functions correctly. I need to call the mouse down event on the handle, then move the mouse position for example 100 pixels up and then call the mouse up event.
This is how it works in Storybook tests:
I have not figured out a way how to test this with the current Vitest browser version (2.1.3). I also asked this on your Discord channel, but there seems to be no way of running these kinds of tests for now.
Beta Was this translation helpful? Give feedback.
All reactions