# TDD

> TDD is an open-source agent skill for developer tools. Guides an agent through red-green-refactor test-first development with vertical slices. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/evist0/okf-matt-skills/tree/main/tdd
- **Repository:** https://github.com/evist0/okf-matt-skills
- **GitHub stars:** 18
- **License:** MIT
- **Skill name:** tdd
- **Collection:** https://github.com/evist0/okf-matt-skills
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-04

## About

This skill is a reference for test-driven development that the agent consults before and during each cycle. It describes what a good test looks like: it checks behavior through public interfaces rather than internal details, and it reads as a specification that survives refactoring. Supporting notes cover where tests belong and mocking guidelines, which the skill links to as separate files.

The workflow centers on seams, the public boundaries where behavior is observed. Before writing any test, the agent is asked to list the seams under test and confirm them with the user, then build in vertical slices: one test, one minimal implementation, repeated. The skill also names common anti-patterns such as tests coupled to implementation, tautological assertions that recompute their own expected values, and writing all tests before any code.

If the project has an OKF knowledge bundle, the skill tells the agent to read its glossary and architecture decision records so test names match the domain vocabulary and existing decisions are respected. Refactoring is treated as a separate review step rather than part of the red-green loop. No scripts are included; the skill is plain instructions.

## When your agent uses it

> Test-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/evist0/okf-matt-skills/tree/HEAD/tdd)
- [License: MIT](https://github.com/evist0/okf-matt-skills/tree/HEAD/tdd)

## Features

- **Behavior-focused testing:** Guides tests toward public interfaces and away from internal implementation details.
- **Seam selection:** Has the agent agree on the public boundaries to test before writing any test.
- **Vertical slice workflow:** Builds one test and one minimal implementation at a time instead of bulk tests first.
- **Anti-pattern checks:** Flags implementation-coupled, tautological and horizontally sliced tests.
- **Red-green discipline:** Requires a failing test before any code and no speculative features.
- **Domain vocabulary alignment:** Uses project glossary and ADR files so test names match domain language.

## Good for

- Build a new feature test-first with red-green-refactor cycles
- Fix a bug by writing a failing test before changing the code
- Write integration tests for a user-facing workflow
- Decide which public seams deserve tests before coding starts
- Review a test suite for implementation-coupled or tautological assertions

## Install

### Claude Code

Copy the skill folder to `~/.claude/skills/tdd` to use it in all your projects:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/evist0/okf-matt-skills.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/tdd &&
cp -R "$tmp/tdd" ~/.claude/skills/tdd &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/tdd` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/tdd` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/evist0/okf-matt-skills.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/tdd &&
cp -R "$tmp/tdd" ~/.agents/skills/tdd &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/tdd` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/tdd` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/evist0/okf-matt-skills.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/tdd &&
cp -R "$tmp/tdd" ~/.cursor/skills/tdd &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/tdd` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/evist0/okf-matt-skills.git --path tdd
```

Or copy the folder to `~/.gemini/skills/tdd` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/tdd`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/evist0/okf-matt-skills.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/tdd &&
cp -R "$tmp/tdd" ~/.copilot/skills/tdd &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/tdd` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/evist0/okf-matt-skills.git
```

Then copy `okf-matt-skills/tdd` into your agent's skills folder as `tdd`. Agents that support SKILL.md read one folder per skill.

## FAQ

### Does TDD need any tools or scripts?

No scripts are included and no allowed tools are set. It is a set of instructions the agent follows while writing tests.

### When does the skill trigger?

It triggers when the user wants to build features or fix bugs test-first, mentions red-green-refactor, or asks for integration tests.

### Does TDD handle refactoring?

Refactoring is not part of the red-green loop. The skill says it belongs to a separate review stage handled by the vet skill.

### Does TDD require a project knowledge bundle?

No. If a knowledge bundle with glossary and ADR folders exists, the agent reads it; otherwise that step is skipped.

### How do I install TDD in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/tdd to use it in all your projects, or to .claude/skills/tdd in one project.

### Does TDD run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use TDD?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to TDD?

The closest alternatives to TDD are TDD, TDD, TDD workflow, Test driven development and TDD loop.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [TDD](https://ai-powered.com/skills/tdd): TDD is an open-source agent skill for developer tools.
- [TDD](https://ai-powered.com/skills/tdd-kripu77): TDD is an open-source agent skill for developer tools.
- [TDD workflow](https://ai-powered.com/skills/tdd-workflow-nabwinsaud): TDD workflow is an open-source agent skill for developer tools.
- [Test driven development](https://ai-powered.com/skills/test-driven-development-addyosmani): Test driven development is an open-source agent skill for developer tools.
- [TDD loop](https://ai-powered.com/skills/tdd-loop): TDD loop is an open-source agent skill for developer tools.
- [Test driven development](https://ai-powered.com/skills/test-driven-development-ajyadav013-2): Test driven development is an open-source agent skill for developer tools.
- [TDD](https://ai-powered.com/skills/tdd-tonyghiani): TDD is an open-source agent skill for developer tools.
- [TDD loop](https://ai-powered.com/skills/tdd-loop-zerotechdebt): TDD loop is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/tdd-evist0
