/review:test-driven-developmentfrom review
TDD methodology for writing reliable, well-tested code. Use before implementation to write failing tests, and after to verify coverage. Triggers on "write tests", "add tests", "TDD", or when starting/completing features.
Ships in review. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The doctrine is stack-agnostic. The project's CLAUDE.md and testing docs name its runners, tiers and colocation rules; they win on mechanics.
The failing test must fail for the right reason: a wrong value, not a missing import or a typo. Watch it fail, then implement. A test you never saw red proves nothing.
Always test-first for:
Test-after is acceptable for UI prototypes, one-off scripts and exploratory spikes.
A stubbed suite, a desktop browser, a headless run and green CI can all pass while the real surface fails: the deployed build, mobile Safari, the real database, the live network. When a test and reality disagree, the test is measuring something else.
A bundle-time or runtime failure outranks a green test. If the harness injects compatibility the shipped runtime lacks, the test is testing a different program.
| Layer | Approach |
|---|---|
| Pure logic | Unit tests. If you need a mock, the logic isn't pure. |
| I/O adapters (DB, network, SDK clients) | Integration test against the real backend when practical; otherwise mock one narrow SDK function. Never hand-roll a fake of a query builder, client or fluent API. |
| State machines | Extract the pure transition decision where possible; test orchestration through the public runtime seam. |
| Background ticks / schedulers | Drive through the entrypoint the platform itself calls, rescheduling from durable state, not in-memory timers. |
| HTTP handlers | Factory-with-deps: the test passes deps to the factory and drives the real routing and middleware. |
Test seams are an escape hatch, not architecture. Prefer the seam production callers already use. When a framework owns construction and leaves no constructor or factory seam, add the smallest one: a single setter plus a read that returns the deps or null. Never grow a production setter, a has* probe or boot-time wiring for a test.
Keep test files next to the source they test, in the project's existing convention.
Integration tests through the seam real callers use carry most of the confidence: handlers with middleware, state machines with real storage, components with the network faked at the boundary. Unit tests cover pure calculation and encoding. End-to-end covers only critical happy paths; it is the slowest and flakiest tier. Follow the project's own ratios when it states them.
"nonsense" as Address, as any) to test a strictly typed internal function. Trust compile-time types internally and schema parsing at external boundaries.min(0).max(7) rejects 99 proves the library works. Test only custom transforms, refinements and regexes.expect(typeof mod.setX).toBe("function") proves nothing. Delete them.Deps interface holds the external effects the workflow must call, not every helper. If it keeps growing, extract pure decisions or move coverage to an integration test.Fixture rules: references/fixtures.md.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub meta-dreamer/md-skills --plugin review3 skills in this plugin
/coderabbit-reviewTriage and fix CodeRabbit PR review comments via parallel topic-based triage and serial fix phases, committing per phase. Cross-checks flagged items with codex when installed. Use when addressing CodeRabbit review on a PR, processing review.json, or running /coderabbit-review. Triggers: address pr comments, coderabbit review, review comments, fix pr review, triage pr review./multi-llm-reviewPressure-test a plan document or a branch diff with external models, Codex (openai-codex plugin) and Gemini (gemini-cli MCP) in parallel, then verify every finding yourself, synthesize, and disposition with the user. Always user-invoked. Use when asked to pressure-test, red-team, or get outside-model review of a design, plan, sprint spec or branch.