vitest

Run Jest-compatible unit tests for Vite projects with watch mode and coverage.

302|22|Updated Feb 12, 2026
One-click install
npx skills add https://github.com/JetBrains/skills --skill vitest-jetbrains
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vitest
Source: https://github.com/JetBrains/skills/tree/main/vitest
Command: npx skills add https://github.com/JetBrains/skills --skill vitest-jetbrains

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Vitest addresses the need for fast, predictable unit tests in Vite-based projects by providing a developer-friendly test runner with a Jest-compatible API, zero-config feel, and first-class support for modern JS/TS features.

Core Features & Use Cases

  • Fast, Vite-native test execution with native ESM support
  • Jest-compatible API for test, describe, expect, mocks, snapshots, and coverage
  • Watch mode, parallel test execution, and multi-project configuration for large codebases
  • Ideal for frontend libraries, React/Vue components, and Node backends needing reliable test feedback

This enables teams to write stable tests that scale from small unit tests to cross-file coverage while integrating with TypeScript, fixtures, and custom reporters.

Quick Start

Install Vitest, write tests with test/describe/expect, and run it with vitest.

Frequently Asked Questions about vitest

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I run unit tests for a Vite project with native ESM support?

Run unit tests for a Vite project with native ESM support using Vitest, a Vite-native test runner that provides configuration-free execution and a Jest-compatible API for your test suites.

Can I use Jest-compatible mocks and snapshots when testing Vite apps?

Yes, you can use Jest-compatible mocks and snapshots when testing Vite apps because this runner provides a familiar API covering test, describe, expect, mocks, and snapshot functionalities out of the box.

Does this test runner support TypeScript and parallel test execution?

Yes, the test runner supports TypeScript and parallel test execution, enabling fast and reliable feedback across modern frontend and Node environments without requiring configuration.

What is the best way to configure multi-project unit testing for large Vite codebases?

The best way to configure multi-project unit testing for large Vite codebases is using Vitest, which supports multi-project workflows, watch mode, and custom reporters to scale test execution reliably.

How do I generate code coverage reports for Vite unit tests?

Generate code coverage reports for Vite unit tests using the built-in coverage functionality of this test runner, which integrates directly into the Vite-native execution pipeline to track cross-file coverage.

Are there limitations when using a Vite-native test runner compared to Jest?

A Vite-native test runner is optimized specifically for Vite-based projects and modern ESM, meaning it may not suit older CommonJS-heavy environments outside the Vite ecosystem, unlike the broadly compatible Jest.