▲ | OptionOfT 19 hours ago | ||||||||||||||||
Vitest does not support CommonJS mocking as of today. I switched to Vitest because Jest was giving me flaky coverage results: https://github.com/nodejs/node/issues/51251 And while Vitest' coverage is stable, I had to add an indirection layer to change how I mock out calls to GitHub's API (@github/octokit). Oh, side note: vite-node's --watch functionality does not restart the process. It does hot reloading which is different enough that it requires some rework at how you set up your app structure and callbacks. | |||||||||||||||||
▲ | pcb-rework 19 hours ago | parent [-] | ||||||||||||||||
The problem is jest is run by megacorp Meta, so it won't be fixed in any reasonable timeframe because they're all about new features to make "impact". Its FOSS contributors are typically slow and working primarily to keep their jobs. Also, with node > 20.9.0 being broken and node = 20.9.0 not being a viable option by being insecure, so it's worth having a look at alternatives like bun or deno because it does seem to have lost its way too. I'm currently pinned to 20.9.0 for system dependencies, but use bun for new dev. | |||||||||||||||||
|