← ClaudeAtlas

test-driven-developmentlisted

Use when implementing ANY feature or bugfix, before writing implementation code. Write the failing test first, watch it fail, write minimal code to pass, refactor. Triggers whenever you are about to write production code, fix a bug, or change behavior — and especially when you catch yourself wanting to "skip tests just this once".
StielChancellor/VibeGod-Tech-Team · ★ 0 · Testing & QA · score 62
Install: claude install-skill StielChancellor/VibeGod-Tech-Team
<!-- Adapted from superpowers (https://github.com/obra/superpowers), MIT (c) Jesse Vincent. --> # Test-Driven Development (TDD) ## Overview Write the test first. Watch it fail. Write minimal code to pass. **Core principle:** If you didn't watch the test fail, you don't know if it tests the right thing. **Violating the letter of the rules is violating the spirit of the rules.** ## Fits in the pipeline TDD is the spine of **Stage 6 (Build)** and the **Stage 5 build plan** is written in TDD steps. The Stage 7 per-feature QA gate and Stage 8 ship gate refuse to advance without green tests. Priority: **user > skills > default**; `_shared/vibegod-principles.md` apply (#8 quality bar: no merge/ship without green; evidence-based completion only). ## When to Use **Always:** new features, bug fixes, refactoring, behavior changes. **Exceptions (ask the user):** throwaway prototypes, generated code, configuration files. Thinking "skip TDD just this once"? Stop. That's rationalization. ## The Iron Law ``` NO PRODUCTION CODE WITHOUT A FAILING TEST FIRST ``` Wrote code before the test? Delete it. Start over. **No exceptions:** don't keep it as "reference", don't "adapt" it while writing tests, don't look at it. Delete means delete. Implement fresh from tests. ## Red-Green-Refactor ```dot digraph tdd_cycle { rankdir=LR; red [label="RED\nWrite failing test", shape=box, style=filled, fillcolor="#ffcccc"]; verify_red [label="Verify fails\ncorrectly", shape=diamond];