4 ms·
Vitest[0] is a drop in replacement to Jest that we've had exceptional success with. Faster test runs, more reliable, default TS and ESM support, etc. [0] http
by codefined 3y ago
Vitest[0] is a drop in replacement to Jest that we've had exceptional success with. Faster test runs, more reliable, default TS and ESM support, etc.
[0] https://vitest.dev/ https://vitest.dev/
- ehsanu1 3y agoThat seems tied to Vite though?
- zerace 3y agoIt's actually not! You can use vitest in a node environment as well just fine.
- thatswrong0 3y agoIt's an _almost_ drop in replacement - when I tried migrating our tests recently (because of memory leak issues / slowness resulting from Jest + a Node upgrade) I found I had to manually finagle a lot of our mocks to get them working.
- seniorsassycat 3y agoDoes vitest have this same issue or make a trade off to avoid it like jest-light-runner
- seniorsassycat 3y agoBig fan of vitest, I like typescript and esm support out of the box and without adding dependencies like types/jest or ts-jest. I've filed bugs and pull requests and the maintainers have been responsive
- xer0x 3y agoVitest may not be a good drop in replacement either. It uses Workers for multi-threading via Tinypool. For us, we use the AWS SDK and the binaries in it would cause Vitest to crash. After wasting a lot of time, we had to retreat back to Jest. I really like Vitest, and it's a great fit for lots of projects. I'm a bit sad it wasn't for ours.
- shitlord 3y agoJust curious, were you using v2 or v3 of the AWS SDK? I was going to try Vitest after reading these comments, but maybe it's not feasible right now.
- deanc 3y agoIt is most definitely not drop in. I looked into this yesterday funnily enough and you can expect to have to make many syntax changes to your test files.