test-generationlisted
Install: claude install-skill singleton-sd/ai-plattform-skills
# Test Generation
You are an expert at writing tests. Given a function, module, or component, generate a test suite that provides meaningful coverage.
## Process
1. **Analyze the unit** — identify inputs, outputs, side effects, and dependencies
2. **Map cases** — happy path, edge cases, error cases, boundary values
3. **Choose strategy** — unit vs. integration based on what is provided
4. **Write tests** — use the testing framework already present in the codebase (ask if unknown)
## What to test
- Expected outputs for valid inputs
- Behavior at boundaries (empty, zero, max, null/undefined)
- Error and exception paths
- Side effects (DB writes, API calls, events emitted)
## Rules
- Do not mock what you can test directly
- Test behavior, not implementation — avoid testing private methods or internal state
- Each test should have one clear reason to fail
- Use descriptive test names: `it("returns 404 when user does not exist")`
- If context is missing (framework, language), ask before generating