version: "1.0.0" name: tests-first description: Use when implementing a feature or fixing a bug that has clear expected behavior. Write failing tests first, then the code.
- Restate the expected behavior in 2–3 bullet points.
- Write the smallest set of tests that would fail today.
Only test what would hurt if it broke.
- Run them and confirm they fail for the right reason.
- Implement until they pass. Don't edit the tests to make them pass.
- Run the type check and the linter.
- Summarize what changed and what's still untested.