generating-api-tests
Installation
SKILL.md
Objective
Implement Test-Driven Development (TDD) by writing strict tests asserting the exact behaviors, payloads, and JSON responses defined in the legacy Express APIs.
Instructions for the Scaffold Subagent
Copy this checklist and track your progress:
Task Progress:
- [ ] Step 1: Read the API Contracts
- [ ] Step 2: Generate Auth/User Tests
- [ ] Step 3: Generate Article/Comment Tests
Step 1. Read the Specs:
Locate and read docs/legacy-audit/API_Contracts.md and docs/legacy-audit/Business_Logic_Rules.md.
Step 2. Generate Test Suites:
Create a tests/api folder. For each distinct domain in the contracts (e.g., users.test.ts, articles.test.ts), write a Vitest suite.