Agent skill

Test Driven Development

by dzhalaevd in dzhalaevd/Donatello

Use as a workflow overlay when implementing any feature, bugfix, refactor, or behavior change before writing production code

Apache-2.0Auto-check passedTesting & QA

Install Test Driven Development

skills CLI
$ npx skills add dzhalaevd/Donatello --skill test-driven-development -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install dzhalaevd/Donatello test-driven-development --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/dzhalaevd/Donatello.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/test-driven-development .claude/skills/test-driven-development && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
test-driven-development
GitHub stars
135
Token cost
~1.1k tokens
SKILL.md length
598 words
Files
2
Skills in repo
15
Repo updated
First seen
Licence
Apache-2.0

At a glance

Use as a workflow overlay when implementing any feature, bugfix, refactor, or behavior change before writing production code

  • Works in 3 steps: Red → Green → Refactor
  • Tasks that involve Test-driven development
  • SKILL.md covers Purpose, When to Use, Core Rule and Red / Green / Refactor, plus 6 more sections
  • Calls pytest

What it does

Test Driven Development is an agent skill from dzhalaevd/Donatello. Use as a workflow overlay when implementing any feature, bugfix, refactor, or behavior change before writing production code

Its SKILL.md is about 1.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files (for example `agents/openai.yaml`).

It sits in Testing & QA, covering Test-driven development and Refactoring. The repository describes itself as: Make Dating Great Again. An open source dating platform. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Test-driven development
  • Tasks that involve Refactoring

Example prompts

  • “/test-driven-development”

Requirements

  • Python 3

Workflow steps

3 steps, taken from the step headings in SKILL.md.

  1. Red
  2. Green
  3. Refactor

What it can do on your machine

Read from SKILL.md and the folder at commit b57816e. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • pytest

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Test Driven Development loads about 1.1k tokens when it runs. Until then it costs about 37 tokens; SKILL.md has 598 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~37
When it runs · the whole SKILL.md, loaded when a task matches
~1.1k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from dzhalaevd/Donatello at commit b57816e, republished under its Apache-2.0 licence (© dzhalaevd). 598 words, ~1,113 tokens.

Download SKILL.mdSave it as .claude/skills/test-driven-development/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
test-driven-development
description
Use as a workflow overlay when implementing any feature, bugfix, refactor, or behavior change before writing production code

Test-Driven Development

Purpose

Use TDD to clarify desired behavior before changing production code. The point is confidence and better design, not ritual for its own sake.

TDD is a workflow overlay, not a replacement for choosing the right test level. Combine it with:

  • unit-testing for isolated behavior;
  • integration-testing for database/API/multi-component behavior;
  • concurrency-fuzzing-testing for race-condition or interleaving bugs;
  • testing-pytest for pytest implementation details.

When to Use

Use this skill for:

  • new features;
  • bug fixes;
  • refactoring that changes structure but should preserve behavior;
  • any behavior change.

Ask the user before skipping TDD for throwaway prototypes, generated code, or pure configuration.

Core Rule

Write the failing test first. Watch it fail for the expected reason. Then write the smallest production change that makes it pass.

If a test passes immediately, it did not prove the new behavior. Fix the test or choose a behavior that is not already covered.

Red / Green / Refactor

1. Red

Write one small test for the next observable behavior.

python
def test_rejects_empty_email(client: Client) -> None:
    response = client.post("/api/users", json={"email": "", "name": "Ada"})

    assert response.status_code == 422
    assert response.json()["detail"]

Run only the relevant test first:

bash
pytest path/to/test_file.py::test_rejects_empty_email

Confirm:

  • the test fails;
  • the failure is expected;
  • it fails because the behavior is missing, not because of a typo, fixture error, or bad setup.
2. Green

Write the minimal production code to pass the test.

Do not add extra options, unrelated refactors, or future behavior. If the next requirement matters, write the next failing test for it.

Run the focused test again, then the relevant nearby test set.

3. Refactor

Only after green:

  • remove duplication;
  • improve names;
  • simplify structure;
  • extract helpers if they reduce real noise.

Keep the tests green during refactoring.

Bug Fix Workflow

For a bug:

  1. Write a failing test that reproduces the bug.
  2. Confirm the test fails on current code.
  3. Fix the bug with the smallest change.
  4. Confirm the new test and related tests pass.
  5. Keep the regression test.

Never fix a backend bug only by manual verification when an automated regression test can reasonably cover it.

Good TDD Tests

A useful first test:

  • names the behavior clearly;
  • uses the public interface;
  • has one main Act;
  • asserts a meaningful public result;
  • mocks only external uncontrolled dependencies;
  • is small enough to fail for one clear reason.

Avoid first tests that:

  • assert private methods or internal call counts;
  • check implementation details before behavior;
  • require a huge fixture setup;
  • use broad mocks that make the test pass without executing real code.
Show full SKILL.md (205 more words)Show less

Existing Code

When changing untested existing code:

  1. Add a characterization test for current behavior if needed.
  2. Add a failing test for the desired new behavior.
  3. Change production code.
  4. Refactor only with tests passing.

If the existing design is hard to test, let that inform the design. Prefer simpler public interfaces and dependency boundaries over heavier test machinery.

When Stuck

If you do not know how to test the behavior:

  • write the assertion first;
  • describe the wished-for public API;
  • reduce the behavior to one smaller case;
  • ask the user for the intended behavior if the product decision is unclear.

If the test setup is huge, consider whether the behavior belongs in a smaller unit test or whether the production design is too coupled.

Completion Checklist

Before marking TDD work complete:

  • Each behavior change has a test.
  • The test was run and failed before implementation.
  • The failure reason was expected.
  • The production change was minimal.
  • Focused tests pass.
  • Relevant surrounding tests pass.
  • Tests verify public behavior rather than internals.

Response Format

When reporting TDD work:

  1. Name the failing test that was added.
  2. Say what failure it produced before implementation.
  3. Summarize the production change.
  4. List the verification commands and results.

© dzhalaevd, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file in .agents/skills/test-driven-development of dzhalaevd/Donatello.

  • SKILL.md
  • agents/openai.yaml

Open the folder on GitHubat commit b57816e

Compare with similar skills

Test Driven Development next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Test Driven Development compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Test Driven Development this skilldzhalaevd/Donatello135—~1.1kAutomated safety check: PassApache-2.0
TDD WorkflowhellangleZ/burn-in-cceverywhere-ralph11211 repos~2.4kAutomated safety check: PassNone
TDD Methodoly Expertthedaviddias/skill-check190—~2.2kAutomated safety check: PassMIT
Implementgenkovich/sdd171—~2.5kAutomated safety check: PassMIT
TDDDanMcInerney/architect-loop626—~730Automated safety check: PassMIT
TDD Workflowaffaan-m/ECC275k1 repos~2.6kAutomated safety check: PassMIT

Similar skills

  • TDD Workflow

    hellangleZ/burn-in-cceverywhere-ralph

    A skill your agent uses when writing new features, fixing bugs, or refactoring code.

    112 GitHub starsUsed in 11 repos~2.4k tokens
    Testing & QAAuto-check passed
  • TDD Methodoly Expert

    thedaviddias/skill-check

    A skill your agent uses when implementing features or fixing bugs with strict Test-Driven Development (TDD).

    190 GitHub stars~2.2k tokensUpdated 4 mo ago
    Testing & QAAuto-check passed
  • Implement

    genkovich/sdd

    A skill your agent uses to implement a feature from its tasks.json with test-driven development — writes a failing test first, makes it pass, refactors, gates, and commits per task.

    171 GitHub stars~2.5k tokensUpdated 1 mo ago
    Testing & QAAuto-check passed
  • TDD

    DanMcInerney/architect-loop

    Test-driven development for factory builders. An agent skill from DanMcInerney/architect-loop.

    626 GitHub stars~730 tokensUpdated 24 days ago
    Testing & QAAuto-check passed
  • TDD Workflow

    affaan-m/ECC

    Yeni özellikler yazarken, hata düzeltirken veya kod refactor ederken bu skill'i kullanın.

    275k GitHub starsUsed in 1 repo~2.6k tokens
    Testing & QAAuto-check passed
  • Fix

    jvm-skills/jvm-skills

    Fix a bug or missing feature using TDD — write failing test first, then fix, refactor, verify, beautify.

    140 GitHub stars~695 tokensUpdated 1 mo ago
    Testing & QAAuto-check passed

More from dzhalaevd/Donatello

All 15 skills in this repo
  • API And Interface Design

    dzhalaevd/Donatello

    Guides stable API and interface design. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 9 repos~2.6k tokens
    Auto-check passed
  • Documentation And Adrs

    dzhalaevd/Donatello

    Records decisions and documentation. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 8 repos~2.4k tokens
    Auto-check: notes
  • CI CD And Automation

    dzhalaevd/Donatello

    Automates CI/CD pipeline setup. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 7 repos~2.7k tokens
    Auto-check: notes
  • Deprecation And Migration

    dzhalaevd/Donatello

    Manages deprecation and migration. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 7 repos~3.1k tokens
    Auto-check passed
  • Instruments code so production behavior is visible and diagnosable.

    135 GitHub starsUsed in 5 repos~2.7k tokens
    Auto-check passed
  • Shipping And Launch

    dzhalaevd/Donatello

    Prepares production launches. An agent skill from dzhalaevd/Donatello.

    135 GitHub starsUsed in 5 repos~2.5k tokens
    Auto-check passed

Categories

Questions about Test Driven Development

What does Test Driven Development do?

Use as a workflow overlay when implementing any feature, bugfix, refactor, or behavior change before writing production code. Test Driven Development is an agent skill from dzhalaevd/Donatello.

When should I use Test Driven Development?

Test Driven Development fits situations like: tasks that involve Test-driven development; tasks that involve Refactoring.

How do I install Test Driven Development in Claude Code?

Run `npx skills add dzhalaevd/Donatello --skill test-driven-development -a claude-code`. Or copy the skill folder (.agents/skills/test-driven-development in dzhalaevd/Donatello) into .claude/skills/test-driven-development in your project. Claude Code loads it when a task matches its description.

How do I install Test Driven Development in Codex?

Run `npx skills add dzhalaevd/Donatello --skill test-driven-development -a codex`. Or copy the skill folder (.agents/skills/test-driven-development in dzhalaevd/Donatello) into .agents/skills/test-driven-development in your project. Codex loads it when a task matches its description.

Can I use Test Driven Development in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add dzhalaevd/Donatello --skill test-driven-development -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/test-driven-development, .gemini/skills/test-driven-development, .github/skills/test-driven-development and .opencode/skills/test-driven-development in your project.

What does Test Driven Development need to run?

Going by SKILL.md and its folder, Test Driven Development needs the command-line tools its instructions call (pytest). Our summary lists: Python 3.

Does Test Driven Development access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Test Driven Development safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Test Driven Development use?

Test Driven Development is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Test Driven Development use?

About 1.1k tokens (SKILL.md is roughly 4.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Test Driven Development?

Skills that share tags, products or a category with Test Driven Development: TDD Workflow (hellangleZ/burn-in-cceverywhere-ralph, 112 stars), TDD Methodoly Expert (thedaviddias/skill-check, 190 stars), Implement (genkovich/sdd, 171 stars) and TDD (DanMcInerney/architect-loop, 626 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Test Driven Development?

dzhalaevd (a GitHub user) maintains it in dzhalaevd/Donatello, which has 135 GitHub stars. The repository holds 15 skills in this directory. The repository was last updated on October 3, 2026.

Source: dzhalaevd/Donatello on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.