What problem does it solve?
It prevents regressions and incorrect implementations by ensuring every new behavior is proven with a failing test before production code is written.
Core Features & Use Cases
- Test-first behavior design: Write the smallest test that captures the intended behavior, watch it fail, then implement only what the test requires.
- Red–Green–Refactor discipline: Keep the workflow tight—RED, mandatory failure verification, minimal GREEN code, mandatory pass verification, then safe refactoring after tests are green.
- Bug fix as a repeatable proof: Reproduce the bug with a failing regression test and verify it stays fixed without breaking other tests.
- Cross-cutting guidance during execution planning: Apply this pattern broadly for new features, bug fixes, and behavior changes, with explicit exemptions when appropriate.
Quick Start
Use the test-driven-development skill to write a failing regression test first, confirm the failure is expected, then add the minimum production code to make the test pass while keeping other tests green.