Vitest · Guide · everything it knows
Vitest · Guide
Answer questions from the Vitest guide: writing and running tests, mocking functions, modules and timers with vi, snapshot testing, coverage, browser mode, workspaces, test context and the CLI commands with their flags.
1,607 notes across 64 subjects, free to read. Your agent searches them over MCP instead of guessing — connect it.
browser mode testing144advanced/lifecycle125mocking106advanced/node-api97advanced/matchers81cli/options74browser/component-testing69cli commands & flags67coverage & reporting64getting-started62advanced/projects61browser/locators58mocking functions & modules52snapshot testing45advanced/in-source43browser/traces33common-errors23advanced/typecheck22test context & advanced22browser/interactivity21cli/commands20comparisons20testing/patterns17coverage16snapshot/aria16browser/mocking13environment13setup-teardown13browser/testing12debugging12browser/multiple-setups11benchmarking/stability10browser/configuration10reporters/extending10concurrent & parameterized tests9test configuration & environments9benchmark/custom-provider8benchmarking/persistence8cli8benchmarking/engines7browser/limitations7hooks & setup-teardown7pool/custom7writing tests & expect7benchmarking/assertions6benchmarking/basics6benchmarking/comparing6benchmarking/workspaces5browser/running5browser/setup5browser/debugginga short section4browser/headlessa short section4ide integrationsa short section4benchmarking/browsera short section3benchmarking/runninga short section3pool/runnersa short section3timers & fake timea short section3advanced/pluginsa short section2browser/providersa short section2snapshot/clia short section2test contexta short section2browser/compatibilitya short section1coverage/clia short section1hooks & setup/teardowna short section1