I am a bit confused with the Angular testing landscape. I have seen that Vitest will become the new default, replacing Karma. The question I then have is what about Jasmine. Does Vitest replace only Karma or the Karma/Jasmine combo. It seems that the docs talk about Vitest being the new test runner (replacing Karma), but there is also a migration from Jasmine to Vitest: refactor-jasmine-vitest. For me it is unclear if I can still use Jasmine in my testing or not?

Also, how does Jest places itself in this story?

I also know that Vitest runs its tests using a emulation lib in nodejs. Karma used to run in a browser. If you want the same experience with Vitest, do you need to configure a browser mode like this: https://next.angular.dev/guide/testing/unit-tests#5-configure-browser-mode-optional ?

1 Reply 1

Vitest is both a test runner and a testing library so it replaces Karma + Jasmine.

Vitest supports both kind test run in node and in browsers.

Your Reply

By clicking “Post Your Reply”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.