test-driven-development is agent-read markdown (skill) from coco-research/coco: Use when implementing any feature or bugfix, before writing implementation code.
Indexed from public GitHub and served as immutable, content-addressed versions. Install it pinned to an exact SHA-256 with the mdr CLI, and every file is verified against the hash recorded here before it reaches your agent. The deterministic audit below grades the latest version, and the same file always earns the same grade.
What the file says
# Test-Driven Development (TDD)
## Overview
**Announce at start:** "Test-Driven Development skill activated."
Write the test first. Watch it fail. Write minimal code to pass.
**Core principle:** If you didn't watch the test fail, you don't know if it tests the right thing.
**Violating the letter of the rules is violating the spirit of the rules.**
## When to Use
**Always:**
- New features
- Bug fixes
- Refactoring
- Behavior changes
**Exceptions (ask your human partner):**
- Throwaway prototypes
- Generated code
- Configuration files
Thinking "skip TDD just this once"? Stop. That's rationalization.
## The Iron Law
```
NO PRODUCTION CODE WITHOUT A FAILING TEST FIRST
```
Write code before the test? Delete it. Start over.
**No exceptions:**
- Don't keep it as "reference"
- Don't "adapt" it while writing tests
- Don't look at it
- Delete means delete
Implement fresh from tests. Period.
## Red-Green-Refactor
```dot
digraph tdd_cycle {
rankdir=LR;
red [label="RED\nWrite failing test", shape=box, style=filled, fillcolor="#ffcccc"];
verify_red [label="Verify fails\ncorrectly", shape=diamond];
…
Pin to a label to follow the author's releases, or to a sha256 to freeze the exact bytes forever. Either way the resolved hash is written to mdr.lock, and mdr install reproduces it on any machine.
GET https://markdownregistry.com/api/v1/artifacts/art_qz6fkaasyk6mhcvl
GET https://markdownregistry.com/api/v1/resolve?ref=coco-research/coco/test-driven-development
GET https://markdownregistry.com/api/v1/blob/52b8686273908621e4e76080616bb8114d3320d94abd34e77f6d1f3893e134d0
Your agent does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
coco-research/coco · adapters/cursor/skills/create-rule/SKILL.md · Create Cursor rules for persistent AI guidance. Use when the user wants to create a rule, add coding standards, set up…
coco-research/coco · adapters/cursor/skills/create-skill/SKILL.md · Guides users through creating effective Agent Skills for Cursor. Use when the user wants to create, write, or author a…
coco-research/coco · adapters/cursor/skills/create-subagent/SKILL.md · Create custom subagents for specialized AI tasks. Use when the user wants to create a new type of subagent, set up…
coco-research/coco · adapters/cursor/skills/update-cursor-settings/SKILL.md · Modify Cursor/VSCode user settings in settings.json. Use when the user wants to change editor settings, preferences…
coco-research/coco · skills/agent-lightning/SKILL.md · Train and optimize AI agents using Microsoft's Agent Lightning framework with reinforcement learning. Use when setting…
coco-research/coco · skills/agent-self-eval/SKILL.md · Post-run self-evaluation system that scores agent output on correctness, clarity, actionability, and conciseness. Use…
coco-research/coco · skills/ai-product/SKILL.md · Use when building AI features into a product: LLM integration, RAG pipelines, guardrails, streaming, AI UX, prompt…
coco-research/coco · skills/api-design-principles/SKILL.md · Use when designing a new REST or GraphQL API, reviewing an API spec before implementation, setting team API standards…
coco-research/coco · skills/arb-review/SKILL.md · Generate an Architecture Review Board (ARB) presentation in Coco Inc's standard 11-slide format. Use when someone asks…
coco-research/coco · skills/arch-index/SKILL.md · Build and validate .arch/index.json — a committed map from each architectural component of this repository to the real…
addyosmani/agent-skills · skills/test-driven-development/SKILL.md · Drives development with tests using the red-green-refactor loop. Use when implementing any logic, fixing any bug, or…
a5c-ai/babysitter · library/methodologies/superpowers/skills/test-driven-development/SKILL.md · Use when implementing any feature or bugfix, before writing implementation code. Enforces RED-GREEN-REFACTOR cycle.
a5c-ai/babysitter · library/methodologies/rpikit/skills/test-driven-development/SKILL.md · Test-first development practice where test specifications are written before production code, integrated into plan…
a5c-ai/babysitter · library/methodologies/cc10x/skills/test-driven-development/SKILL.md · Strict RED-GREEN-REFACTOR cycle enforcement. Tests are never skipped or deferred. Run mode only, never watch mode. Exit…
ganyuanran/aegis · skills/test-driven-development/SKILL.md · Use when the user explicitly requests strict or test-first TDD, or when the current conversation already contains an…