cofounder-testing
Installation
SKILL.md
Automated Testing
Tests are written in tandem with the code they verify. Create handler → create test file. Create interactive component → create test file.
The Two Layers
| Layer | What it tests | Requires |
|---|---|---|
| 1. Backend unit/integration | Handlers, queries, logic | Database only |
| 2. Frontend components | UI logic, rendering, interactions | Nothing (simulated DOM) |
Layer 1 tests the API contract against a real database. Layer 2 tests UI logic, rendering, and user interactions with mocked API calls.
Running commands
All invocations must use mise x -- (e.g., mise x -- go test, mise x -- npx vitest). Never invoke tools directly.
Setup Sequence
When starting a new project, set up both layers as the first features are being built. For each layer, look up the current recommended test runner and libraries for the project's language and framework, then configure accordingly. The sections below describe what to test and how much — not which specific library to use.