From sdd
Enforces Red-Green-Refactor TDD cycle: write failing tests first for new classes/methods, add minimal passing code, then refactor. No production code without failing test.
How this skill is triggered — by the user, by Claude, or both
Slash command
/sdd:test-driven-developmentThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
**No production code without a failing test first.**
No production code without a failing test first.
If you have written production code before a failing test:
There are no exceptions. "This is too simple to need a test first" is rationalisation.
Write the smallest amount of production code that makes the test pass. Do not add logic that isn't required by a failing test.
Clean the code while keeping tests green:
For each public method, write at minimum:
| Thought | Reality |
|---|---|
| "This is too simple to need a test" | Simple code breaks too. Write the test. |
| "I'll write tests after to save time" | You won't. The test discovers design flaws. |
| "The test would just mirror the implementation" | Then the implementation is too tightly coupled. |
| "Integration tests cover this" | Unit tests run in milliseconds. Write both. |
Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.
npx claudepluginhub tstapler/dotfiles --plugin sdd