| name | tdd |
| description | Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests. |
TDD Adapter
Thin tool adapter. Authoritative guide: Harness/specs/protocols/TDD-GUIDE.md.
Invocation
- Claude Code: use
/tdd or select the tdd skill.
- Codex CLI or IDE: use
$tdd or /skills then choose tdd.
Load
Harness/specs/protocols/ACCEPTANCE_PROTOCOL.md
Harness/specs/protocols/HARNESS_BRIDGE.md
Harness/specs/protocols/AGENT_ISOLATION.md
Harness/specs/protocols/TDD-GUIDE.md
- ECC stack-specific testing rules (for example
typescript/testing.md, python/testing.md)
- Current task
PLAN.md
Rules
- AC first: Tests are derived from PRD acceptance criteria and must reference AC IDs.
- RED first: Write failing tests before ANY implementation code.
- UI means real user path: Browser-visible behavior requires Playwright/CDP or documented real-browser clicks, typing, navigation, and visible assertions.
- No syntax-only acceptance: Typecheck, lint, build, import tests, shallow renders, and snapshots cannot satisfy browser-visible ACs by themselves.
- Network-aware: Frontend-backend ACs require URL, method, payload, response, and duplicate-request assertions when applicable.
- GREEN minimal: Write only enough implementation to pass the AC-linked tests.
- REFACTOR safe: Improve code while keeping all tests green.
- Coverage gate: Meet the configured project coverage threshold before marking task complete.
- AAA structure: Arrange -> Act -> Assert.
- Role isolation: Test Writer must not reverse-engineer tests from implementation code. Implementer must not modify PRD, AC, UI contract, or API contract except through Change Request.
- Evidence required: Record RED, GREEN, full-check output, and for UI flows screenshot/trace/video/log evidence plus an AC-by-AC result matrix.
- WF-MAX: Acceptance/Test Writer wave completes before any Implementer wave starts.