vitest

द्वारा supabase

Vite द्वारा संचालित तीव्र यूनिट परीक्षण फ्रेमवर्क जिसमें Jest-संगत API है। परीक्षण लिखने, मॉकिंग करने, कवरेज कॉन्फ़िगर करने या परीक्षण के साथ काम करते समय उपयोग करें।

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

supabase की और Skills

studio-e2e-tests
supabase
Supabase Studio के लिए Playwright E2E परीक्षण लिखें और चलाएं। जब पूछा जाए तब उपयोग करें।
official
skill-creator
supabase
मॉड्यूलर स्किल बनाने के लिए व्यापक मार्गदर्शिका जो विशेष ज्ञान और वर्कफ़्लो के साथ क्लॉड की क्षमताओं का विस्तार करती है। स्किल में एक आवश्यक SKILL.md फ़ाइल होती है जिसमें YAML फ्रंटमैटर और मार्कडाउन निर्देश होते हैं, साथ ही वैकल्पिक बंडल संसाधन (स्क्रिप्ट, संदर्भ, एसेट) उद्देश्य के अनुसार व्यवस्थित होते हैं और संदर्भ को संरक्षित करने के लिए क्रमिक रूप से लोड किए जाते हैं। ठोस उपयोग उदाहरणों के आसपास
official
supabase
supabase
किसी भी Supabase से संबंधित कार्य करते समय उपयोग करें। ट्रिगर: Supabase उत्पाद (डेटाबेस, प्रमाणीकरण, एज फंक्शन्स, रियलटाइम, स्टोरेज, वेक्टर्स, क्रॉन, क्यूज़); क्लाइंट…
official
supabase-server
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
उन PRs की समीक्षा करते समय उपयोग करें जो packages/dev-tools/, packages/common/posthog-client.ts को छूते हैं,
official
e2e-studio-tests
supabase
स्टूडियो ऐप में e2e परीक्षण चलाएँ। जब e2e परीक्षण चलाने, स्टूडियो परीक्षण चलाने, प्लेराइट परीक्षण चलाने, या फीचर का परीक्षण करने के लिए कहा जाए तो इसका उपयोग करें।
official
safe-sql-execution
supabase
Safely execute SQL queries against a user database without risking SQL injection or other security vulnerabilities.
official