/agent-skills:test-driven-developmentfrom agent-skills
Guides through test-first development cycles: red (failing test), green (minimal code), refactor. Use when building features test-first or fixing reliably reproducible bugs.
Ships in agent-skills. 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.
None: SKILL.md is the whole skill.
TDD is a design technique that produces tests as a by-product. The tests are valuable; the design pressure is the point. Writing the test first forces you to use the interface before you build it, and interfaces that are painful to call are painful to test — you find out in thirty seconds instead of after the implementation is finished.
The cycle is small on purpose. If a cycle takes more than a few minutes, the step was too big.
One behaviour, stated from the caller's side. Run it and watch it fail.
Watching it fail is not ceremony. A test that passes before the code exists is testing nothing, and this is a genuinely common mistake — a typo'd assertion, a test the runner never collected, a mock that satisfies itself. The failure message is also your first piece of design feedback: if it is incomprehensible, fix the test now.
Done when: the test fails, and it fails for the reason you intended.
Write the least code that passes. Hardcoding a return value is legitimate here — it is a placeholder that the next test will force you to generalize.
Resist implementing what the next test will need. That is the discipline the whole technique rests on: code that is not yet demanded by a test is code with no specification.
Done when: the new test passes and every other test still passes.
Now improve the code, with tests passing the entire time. Rename, extract, remove the duplication the last cycle introduced. Run the tests after each step.
Refactor the tests too. Test code rots faster than production code precisely because people treat it as exempt.
Done when: the code says what it means and the bar is still green.
The order of tests is the order in which you discover the design, so it matters.
null, not the empty list — a
genuine, minimal example of the actual job.This is where TDD pays for itself most obviously:
Step 4 is what proves the fix caused the pass. Without it you have correlation.
Test at the boundary a caller actually uses. Tests bound to internals break on every refactor and produce the belief that "tests slow us down", which is true of those tests.
Prefer real collaborators over mocks. Mock what is slow, non-deterministic, or outside your control — clock, network, filesystem, payment provider. Every other mock is a guess about someone else's behaviour, and it passes happily while production fails.
Be honest about this rather than forcing it:
Say so when it applies. Forcing TDD where it does not fit is how teams conclude it does not work anywhere.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
tdd, red-green-refactor, test-first, test-driven-development
npx claudepluginhub arjunprabhulal/agent-skills --plugin agent-skills60 skills in this plugin
/accessibility-reviewReviews an interface for barriers that stop people using it — keyboard operation, screen reader support, contrast, focus management, and form semantics. Use this whenever the user is building or reviewing UI, mentions accessibility, a11y, WCAG, screen readers, or keyboard navigation, and proactively when a change adds a modal, a custom control, a form, or anything interactive. For general code correctness, use code-review./agent-deploymentShips an agent to production — packaging, config and secrets, staged rollout, and the rollback plan — for a system whose failures are usually silent rather than loud. Use this whenever the user is deploying an agent or LLM feature, planning a rollout or canary, moving an agent from prototype to production, or asking how to release a prompt or model change safely. For monitoring it once live, use agent-observability./agent-designDesigns an agent's architecture — the tool surface, context strategy, control flow, and model choice — from a scoped set of jobs. Use this whenever the user is deciding how an agent should be built rather than what it should do — choosing tools, wiring up an agent loop, deciding single-agent vs multi-agent, picking a model, or planning what goes in the context window. Also use when an existing agent is unreliable and the cause looks structural rather than a prompt problem. For deciding what the agent is for, use agent-scoping first./agent-evaluationBuilds an eval set for an agent or LLM feature, writes graders, establishes a baseline, and reads the results honestly. Use this whenever the user wants to measure whether an agent works, asks if a prompt or model change was an improvement, mentions evals, LLM-as-judge, regression testing for AI, or is about to ship an agent on the strength of a few manual tries. Also use before any prompt or model change, since without a baseline no change can be judged./agent-hardeningMakes an agent safe to run with real permissions on real data — scoping what it can do, handling prompt injection, adding confirmation and dry-run for irreversible actions, and bounding cost. Use this whenever an agent is about to touch production, act autonomously, handle untrusted input, or use credentials, and whenever the user asks about agent safety, guardrails, permissions, or prompt injection. Also use when an agent has broad API access that nothing in code restricts./agent-implementationBuilds an agent from a design — the loop, the tools, the prompts, the schema validation, and the traces you will need later. Use this whenever the user is writing agent code — implementing tool calling, wiring an agent loop, building an MCP server or tool layer, writing system prompts for an agent, or turning a prototype agent into something maintainable. For deciding the architecture first, use agent-design; for measuring whether it works, use agent-evaluation.Other plugins' skills for the same job