Tdd
Test-driven development discipline. Use whenever writing or modifying production code — implementing a feature or fixing a bug. Not needed for docs, config, or pure test changes.From its SKILL.md
npx -y skills add craftycorvid/powers --skill tddAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
1.8 KB, as published. Nobody here has run it
TDD
The Iron Law
No production code without a failing test that demands it. If production code exists before its test, delete it and start again from the test — code written first tends to get a test written to pass, which proves nothing.
Features
- Write the smallest failing test for the next behavior.
- Run it. Watch it fail for the right reason — a failure message about the missing behavior, not a typo, import error, or setup problem.
- Write the minimal production code that makes it green. Resist generality the test doesn't force.
- Refactor with the test green.
- Commit. Where practical, commit in pairs per task:
test: ...thenfeat: ...— the history shows each behavior was demanded before it existed.
Bugs
The failing test is the bug report made executable:
- Reproduce the bug as a failing test before touching the fix. If you can't write a test that fails, you don't yet understand the bug.
- Fix it. Watch the test go green.
- Check for siblings: would the same test pattern catch the same mistake elsewhere (other call sites, other input classes, the copy-pasted twin)? Add those tests while the context is loaded.
Escape Hatch
Check the host repo's CLAUDE.md for a VERIFY_LEVEL= line. If it says
VERIFY_LEVEL=build, the hard gate in that repo is only that the build/verify
passes — tests are still the right way to work, but src-without-tests won't be
blocked. Default (VERIFY_LEVEL=tdd or no line) means the gate enforces this
skill: source changes without accompanying test changes will be rejected.