Test-Driven Development is a skill from Superpowers, Jesse Vincent's open-source methodology for coding agents (skill source). It activates whenever an agent implements a feature or fixes a bug, before any implementation code is written, and holds the agent to strict red-green-refactor.
Its core claim: if you did not watch the test fail, you do not know whether it tests the right thing.
Key Features
- The iron law: "No production code without a failing test first." Code written before its test is deleted and rewritten from the test, not kept "as reference".
- Verify red: the agent runs the test and confirms it fails for the expected reason (missing feature, not a typo). A test that passes immediately is testing existing behavior.
- Minimal green: only enough code to pass. The skill shows an over-engineered retry function with unrequested options as the thing to avoid.
- Whole-suite check: a green run of the new test file is not a green suite; the agent runs the project's full test command and reports any failure by name.
- Rationalization table: rebuttals to "too simple to test", "I'll test after" and "already manually tested".
- Companion file
writing-good-tests.mdon test quality.
Use Cases
- New features, bug fixes, refactors and behavior changes.
- Exceptions the skill allows only with your approval: throwaway prototypes, generated code and configuration files.
Pricing
Free and open source under the MIT license. Prime Radiant, the company behind Superpowers, sells commercial support to enterprises. The practical cost is tokens: process skills add questions, reviews and subagent runs.
Getting Started
Superpowers installs as one plugin, so this skill arrives with the rest of the library (15 skills in v6.4.1). In Claude Code run /plugin install superpowers@claude-plugins-official. Cursor uses /add-plugin superpowers, Gemini CLI uses gemini extensions install https://github.com/obra/superpowers, and the README lists commands for Codex, GitHub Copilot CLI, OpenCode, Pi and other harnesses. Skills trigger on their own; you can also ask for one by name. Then ask for a feature normally and watch for the failing test before the implementation.
Limitation: the rules are strict by design. Deleting pre-written code can feel wasteful, and projects without a fast test runner will slow the loop down.
FAQ
Does it work outside JavaScript?
Yes. Examples use TypeScript, but the process is language-agnostic and names pytest and cargo test too.
Can I skip it for a spike?
Ask for a throwaway prototype explicitly; that is a listed exception.
Alternatives
- Skills for Real Engineers: Matt Pocock's pack, which also includes a TDD skill.
- Code Testing Generator: generates tests for existing code rather than test-first.
- Verification Before Completion: the sibling skill that checks claims before "done".
Conclusion
The skill that most changes how an agent writes code. Pair it with Systematic Debugging for bug work. More in the skills hub.
Comments
No comments yet. Be the first to comment!
Related Tools
Related Insights
Skills + Hooks + Plugins: How Anthropic Redefined AI Coding Tool Extensibility
An in-depth analysis of Claude Code's trinity architecture of Skills, Hooks, and Plugins. Explore why this design is more advanced than GitHub Copilot and Cursor, and how it redefines AI coding tool extensibility through open standards.

Anthropic Subagent: The Multi-Agent Architecture Revolution
Deep dive into Anthropic multi-agent architecture design. Learn how Subagents break through context window limitations, achieve 90% performance improvements, and real-world applications in Claude Code.

Claude Code account precautions: before you spend $200, do these six things
Gmail plus Apple private sign-in, Cliproxy residential routing for CC and emulators, IP/DNS checks, gradual upgrades, and history-preserving sign-out. Includes a profile and script.