qa-vitest-writer

Generate Vitest unit and integration tests for TypeScript projects.

2|2|Updated Mar 7, 2026
One-click install
npx skills add https://github.com/AZANIR/qa-skills --skill qa-vitest-writer
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: qa-vitest-writer
Source: https://github.com/AZANIR/qa-skills/tree/main/.cursor/skills/qa-vitest-writer
Command: npx skills add https://github.com/AZANIR/qa-skills --skill qa-vitest-writer

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill automates the creation of Vitest unit and integration tests for TypeScript projects, streamlining the testing process and ensuring code quality.

Core Features & Use Cases

  • Automated Test Generation: Writes Vitest tests from provided test case specifications.
  • Mocking & Fixtures: Integrates mocks (vi.mock, vi.fn, vi.spyOn) and fixtures.
  • Jest Migration: Assists in migrating existing Jest tests to Vitest.
  • Use Case: You have a new TypeScript module and need to write comprehensive unit tests. Provide the test cases, and this Skill will generate the *.test.ts files with appropriate Vitest syntax, mocks, and assertions.

Quick Start

Use the qa-vitest-writer skill to generate Vitest tests for the 'userService' module based on the provided test cases.

Frequently Asked Questions about qa-vitest-writer

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

FAQPage Schema
How do I generate Vitest unit tests for a TypeScript module?

To generate Vitest unit tests, provide your TypeScript module and test case specifications. The skill outputs *.test.ts files with appropriate Vitest syntax, mocks, and assertions automatically.

Can I migrate my existing Jest tests to Vitest?

Yes, you can migrate Jest tests to Vitest. The skill assists with Jest migration by converting existing tests to use Vitest's Jest-compatible APIs and Vite integration.

How do I set up mocks and fixtures in Vitest?

Setting up mocks and fixtures in Vitest involves using vi.mock, vi.fn, and vi.spyOn. The skill integrates these mocking methods into your generated TypeScript test files.

Does this Vitest generator support ESM and Vite integration?

Yes, this Vitest generator supports ESM and Vite integration. It writes unit and integration tests for TypeScript projects configured with these modern module systems.

What is the best way to configure test coverage in Vitest?

Configuring coverage in Vitest is handled by the skill during test generation. It automates test creation from specifications and configures coverage settings for your TypeScript project.

How do I write parameterized tests in Vitest?

Writing parameterized tests in Vitest is automated by providing your test case specifications. The skill generates the parameterized test structures alongside mocks and fixtures.