/code-testing-agent:tdd-fixfrom code-testing-agent
Fixes bugs via TDD with up to 10 red-green iterations. Writes a failing test then autonomously iterates until the bug is resolved. Use when the user asks to TDD-fix a bug or run a red-green cycle.
Ships in code-testing-agent. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description, though model invocation is off: only you can start it.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Given a bug description, write a failing test that reproduces it, then loop —
run tests, analyze failures, edit code, re-run — until green or 10 iterations,
logging each hypothesis. Then sweep the full suite, commit with a fix: prefix,
and open a PR.
Freedom level: Strict — Follow these steps in order. Do not skip or combine steps. Stop at each hard-stop marker.
Does not design tests from scratch — use code-testing-agent. Does not review test quality — use reviewing-tests.
references/fix-loop.md — Step 2's red phase, Step 3's iteration log and 3a–3c, Step 4's hard capreferences/handoff.md — Step 5's regression sweep, Step 6's summary block, Steps 7–8's commit-agent and pr-agent handoffsUse TodoWrite to create todos for Steps 1–9, all status: "pending".
Mark each status: "completed" as you finish it.
Extract from the invocation message:
| Field | What to extract |
|---|---|
| Symptom | What the code currently does wrong |
| Expected behavior | What it should do instead |
| Affected file(s) | Source file(s) holding the bug — explicit path, or inferred |
| Test file | Its test file (infer from naming convention if not given) |
If a field is missing and cannot be inferred, use AskUserQuestion for
that field only. Do not ask for everything at once.
Do not open any source file yet. Only parse the message.
Read references/fix-loop.md now and follow its Step 2: locate the test file,
append one failing case, edit no production code, run it once to confirm it
fails. A test that passes here is a hard stop — ask, do not enter the loop.
Per references/fix-loop.md Step 3: hypothesis (3a), minimal Edit (3b), scoped
test run (3c), logging and showing every iteration. PASS exits to Step 5; FAIL at
i == 10 goes to Step 4.
Ten iterations without green is the cap. Print the full log and the stop message
from references/fix-loop.md, then STOP — no commit, no PR.
Read references/handoff.md and run its Step 5: the full suite, no scope
filter. A previously-passing test that now fails is a hard stop — report the
regressions and STOP without committing.
Print the summary block defined in references/handoff.md before committing.
Invoke commit-agent as a delegated sub-step per references/handoff.md: type fix, scope from the
most-changed top-level directory. Do not duplicate its staging or hook logic.
Invoke pr-agent per references/handoff.md, including the Step 3 log under a
## How it was found (tdd-fix) section.
STOP here. Do not analyze code further, re-run tests, suggest refactors or
cleanup, or open additional issues. The fix is complete when pr-agent returns
the PR URL.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub shawn-sandy/agentics --plugin code-testing-agent2 plugins ship this exact skill · first indexed Oct 9, 2026
6 skills in this plugin
/code-testing-agentSuggests purpose-driven tests tied to actual behavior. Writes test files covering untested paths and behavior gaps in the codebase. Use when the user asks to suggest tests or find untested behavior./reviewing-testsAudits tests for quality, coverage, and code alignment. Identifies gaps, redundant tests, and misaligned assertions. Use when the user asks to review, audit, or improve a test suite./running-testsDetects the test framework and runs scoped tests. Reports pass/fail results with output and identifies failing assertions. Use when the user asks to run tests, check if tests pass, or verify changes.Other plugins' skills for the same job