paniolo-vitest-test-mock-best-practices
Installation
SKILL.md
Requires: file-read, terminal (test runner). No network access needed.
Related skills:
vitest-test-best-practices/SKILL.md,
vitest-test-hook-best-practices/SKILL.md
Vitest Test Mock Best Practices
Use When
- Writing or updating tests whose main challenge is mocking dependencies.
- Choosing between
vi.mock,vi.spyOn,vi.doMock, or helper-based stubs. - Reviewing whether a test's mock seam is appropriate.
Full reference
vitest-mock — load on demand for the canonical mock patterns and deep-link targets below.