I started using Vite because it's so fast and does everything I need it to. So it seemed logical to give Vitest a go.
I tried using it with React, and React Testing Library. Although the set up was a little different, everything else was the same. Even the way you write tests is the same as using Jest and React Testing Library.
And on top of that, it's fast. Jest would count up the number of seconds you were waiting. If the test failed it would be a longer wait. And it would always be at least 100 seconds, which is a long time to sit around and learn that you'd made a typo.
Vitest, on the other hand, takes about 2 seconds at most. It's not instant, but in comparison to Jest, it feels like it is. Much as I was a convert to Vite, because it's fast, I'm not a convert to Vitest, because it's fast.
Top comments (0)