Vitest logo

Vitest

A Vite-native unit test framework. It's fast!
99
33
+ 1
0

What is Vitest?

It is a blazing fast unit test framework powered by Vite. It aims to position itself as the Test Runner of choice for Vite projects, and as a solid alternative even for projects not using Vite.
Vitest is a tool in the Testing Frameworks category of a tech stack.
Vitest is an open source tool with 11.7K GitHub stars and 1K GitHub forks. Here’s a link to Vitest's open source repository on GitHub

Who uses Vitest?

Companies
29 companies reportedly use Vitest in their tech stacks, including SplitC, Voiceflow, and yaesu.

Developers
66 developers on StackShare have stated that they use Vitest.

Vitest Integrations

Visual Studio Code, TypeScript, IntelliJ IDEA, WebStorm, and Jest are some of the popular tools that integrate with Vitest. Here's a list of all 6 tools that integrate with Vitest.

Vitest's Features

  • Vite's config, transformers, resolvers, and plugins
  • Use the same setup from your app to run the tests!
  • Smart & instant watch mode, like HMR for tests!
  • Components testing for Vue, React, Svelte, Lit and more
  • Out-of-box TypeScript / JSX support
  • ESM first, top level await
  • Workers multi-threading via tinypool
  • Filtering, timeouts, concurrent for suite and tests
  • Jest-compatible Snapshot
  • Chai built-in for assertions + Jest expect compatible APIs
  • Tinyspy built-in for mocking
  • happy-dom or jsdom for DOM mocking
  • Native code coverage via c8
  • Rust like in-source testing

Vitest Alternatives & Comparisons

What are some alternatives to Vitest?
JUnit
JUnit is a simple framework to write repeatable tests. It is an instance of the xUnit architecture for unit testing frameworks.
RSpec
Behaviour Driven Development for Ruby. Making TDD Productive and Fun.
PHPUnit
PHPUnit is a programmer-oriented testing framework for PHP. It is an instance of the xUnit architecture for unit testing frameworks.
pytest
A framework makes it easy to write small tests, yet scales to support complex functional testing for applications and libraries. It is a mature full-featured Python testing tool.
Mockito
It is a mocking framework that tastes really good. It lets you write beautiful tests with a clean & simple API. It doesn’t give you hangover because the tests are very readable and they produce clean verification errors.
See all alternatives
Related Comparisons
No related comparisons found

Vitest's Followers
33 developers follow Vitest to keep up with related blogs and decisions.