testing-patterns

Provide testing patterns for Next.js App Router applications with Supabase.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/vassovass/scl-v3 --skill testing-patterns-vassovass
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: testing-patterns
Source: https://github.com/vassovass/scl-v3/tree/main/.claude/skills/testing-patterns
Command: npx skills add https://github.com/vassovass/scl-v3 --skill testing-patterns-vassovass

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides ready-to-use testing patterns for Next.js App Router applications integrated with Supabase to prevent regressions and accelerate quality assurance.

Core Features & Use Cases

  • Vitest-based unit/integration testing for hooks, components, and utilities.
  • Playwright-based end-to-end testing for real user flows against a running instance.
  • Mock data factories and utilities to simulate Supabase responses, auth states, and API routes.
  • Use cases include adding new features, verifying fixes, and preventing regressions across complex app routes.

Quick Start

Use this skill to scaffold and run tests for a Next.js app using App Router and Supabase.

Frequently Asked Questions about testing-patterns

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

FAQPage Schema
How do I set up testing for a Next.js app with Supabase?

Testing Next.js and Supabase applications requires unit tests with Vitest for components and hooks, integration tests for API routes, and end-to-end tests with Playwright for real user flows. This skill provides ready-to-use patterns, mock factories, and example commands to scaffold a complete testing framework for App Router projects.

Can I use Playwright for end-to-end testing with Next.js and Supabase?

Yes. Playwright end-to-end testing works with Next.js App Router and Supabase by running tests against a live application instance. This skill includes Playwright patterns that verify real user workflows, authentication states, and Supabase interactions without requiring manual test execution.

What's the best way to mock Supabase responses in Next.js tests?

Mock data factories simulate Supabase responses, auth states, and API routes consistently across tests. This skill provides ready-to-use mock utilities and Vitest patterns that enable reliable, repeatable unit and integration tests for Supabase interactions without hitting a live database.

Do I need separate testing tools for components, APIs, and end-to-end flows?

This skill consolidates testing across layers: Vitest handles unit and integration tests for components, hooks, and utilities; Playwright handles end-to-end user flows. A unified mock data layer prevents regressions across all test types in Next.js App Router projects.

How do I prevent regressions when adding features to a Next.js + Supabase app?

Regression prevention requires test coverage across unit, integration, and end-to-end layers. This skill provides patterns for each layer, example test cases for typical use cases, and clear commands to run tests locally or in CI, catching breaks before deployment.