Comment

Comment by OptionOfT

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.

parent OptionOfT 1 year ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton