test-driven-development · diff
git:20260412.c1ced66 to git:20261107.b65d54e
0 added, 4 removed. Audit A to A.
What this update changes in the checks
No check changed: every fixed check gives the same answer before and after this update.
A tripped check is a label, not a verdict: read the matched text and the lines below. This week's updates that newly trip a check.
---
name: test-driven-development
description: Drive changes with Red→Green→Refactor; ensure behavior is verifiable and regression-safe.
---
# Test-Driven Development
- ## Overview
-
- TDD uses the **Red → Green → Refactor** micro-cycle. First, define expected behavior. Next, use a minimal implementation to pass the test. Finally, organize the code structure.
-
## When to Use
- Adding or modifying core logic.
- Fixing bugs and needing regression protection.
- Requirements can be written as explicit input/output acceptance tests.
## Workflow
1. **Red**: Write a failing test describing the expected behavior.
2. **Green**: Write the minimal code to make the test pass.
3. **Refactor**: Clean up naming, structure, and duplication.
4. Repeat the cycle until acceptance criteria are met.
## Ironclad Rules
- Do NOT write massive amounts of features before writing tests.
- Focus on one small goal per cycle.
- All tests MUST pass after refactoring.