vitest

Marco de pruebas unitarias rápidas Vitest impulsado por Vite con API compatible con Jest. Úselo al escribir pruebas, simular, configurar cobertura o trabajar con pruebas...

npx skills add https://github.com/supabase/supabase --skill vitest

Vitest is a next-generation testing framework powered by Vite. It provides a Jest-compatible API with native ESM, TypeScript, and JSX support out of the box. Vitest shares the same config, transformers, resolvers, and plugins with your Vite app.

Key Features:

  • Vite-native: Uses Vite's transformation pipeline for fast HMR-like test updates
  • Jest-compatible: Drop-in replacement for most Jest test suites
  • Smart watch mode: Only reruns affected tests based on module graph
  • Native ESM, TypeScript, JSX support without configuration
  • Multi-threaded workers for parallel test execution
  • Built-in coverage via V8 or Istanbul
  • Snapshot testing, mocking, and spy utilities

The skill is based on Vitest 3.x, generated at 2026-01-28.

Core

TopicDescriptionReference
ConfigurationVitest and Vite config integration, defineConfig usagecore-config
CLICommand line interface, commands and optionscore-cli
Test APItest/it function, modifiers like skip, only, concurrentcore-test-api
Describe APIdescribe/suite for grouping tests and nested suitescore-describe
Expect APIAssertions with toBe, toEqual, matchers and asymmetric matcherscore-expect
HooksbeforeEach, afterEach, beforeAll, afterAll, aroundEachcore-hooks

Features

TopicDescriptionReference
MockingMock functions, modules, timers, dates with vi utilitiesfeatures-mocking
SnapshotsSnapshot testing with toMatchSnapshot and inline snapshotsfeatures-snapshots
CoverageCode coverage with V8 or Istanbul providersfeatures-coverage
Test ContextTest fixtures, context.expect, test.extend for custom fixturesfeatures-context
ConcurrencyConcurrent tests, parallel execution, shardingfeatures-concurrency
FilteringFilter tests by name, file patterns, tagsfeatures-filtering

Advanced

TopicDescriptionReference
Vi Utilitiesvi helper: mock, spyOn, fake timers, hoisted, waitForadvanced-vi
EnvironmentsTest environments: node, jsdom, happy-dom, customadvanced-environments
Type TestingType-level testing with expectTypeOf and assertTypeadvanced-type-testing
ProjectsMulti-project workspaces, different configs per projectadvanced-projects

Más skills de supabase

studio-e2e-tests
supabase
Escribe y ejecuta pruebas E2E con Playwright para Supabase Studio. Úsalo cuando te lo pidan.
official
skill-creator
supabase
Guía completa para crear habilidades modulares que extienden las capacidades de Claude con conocimientos especializados y flujos de trabajo. Las habilidades consisten en un archivo SKILL.md obligatorio con frontmatter YAML e instrucciones en markdown, además de recursos opcionales empaquetados (scripts, referencias, activos) organizados por propósito y cargados progresivamente para conservar el contexto. Diseñe habilidades en torno a ejemplos de uso concretos; identifique scripts reutilizables para tareas deterministas, archivos de referencia para conocimiento del dominio y activos para...
official
supabase
supabase
Úsalo al realizar CUALQUIER tarea que involucre Supabase. Activadores: productos de Supabase (Base de datos, Autenticación, Funciones Edge, Tiempo real, Almacenamiento, Vectores, Cron, Colas); cliente…
official
supabase-server
supabase
Úsalo al escribir código del lado del servidor con Supabase — Edge Functions, aplicaciones Hono, manejadores de webhooks o cualquier backend que necesite autenticación y creación de cliente de Supabase.…
official
clickhouse-logs-queries
supabase
Write, review, and migrate Supabase logs queries against the ClickHouse-backed `logs` table (the `logs.all.otel` analytics endpoint). Use this whenever a task…
official
dev-toolbar-review
supabase
Úsalo al revisar PRs que afecten packages/dev-tools/, packages/common/posthog-client.ts,
official
e2e-studio-tests
supabase
Ejecuta pruebas e2e en la aplicación Studio. Úsalo cuando se te pida ejecutar pruebas e2e, pruebas de Studio, pruebas de Playwright o probar la funcionalidad.
official
safe-sql-execution
supabase
Safely execute SQL queries against a user database without risking SQL injection or other security vulnerabilities.
official