Agent skill

TDD Guide

by borghei in borghei/Claude-Skills

Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support.

MITAuto-check passedTesting & QA

Install TDD Guide

skills CLI
$ npx skills add borghei/Claude-Skills --skill tdd-guide -a claude-code

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

GitHub CLI
$ gh skill install borghei/Claude-Skills tdd-guide --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/borghei/Claude-Skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/engineering/tdd-guide .claude/skills/tdd-guide && 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
tdd-guide
GitHub stars
881
Token cost
~1.7k tokens
SKILL.md length
649 words
Files
21 (incl. scripts, references, assets)
Skills in repo
349
Repo updated
First seen
Licence
MIT

At a glance

Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support.

  • Writing tests first
  • SKILL.md covers Core Capabilities, When to Use, Clarify First and Quick Start, plus 3 more sections
  • Runs Python scripts from its folder
  • Analyzing coverage

What it does

TDD Guide is an agent skill from borghei/Claude-Skills. Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support. Use when writing tests first, analyzing coverage, generating test stubs, or converting tests between Jest, Pytest, JUnit, and Vitest.

Its SKILL.md is about 1.7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 23 other files, including scripts, reference files and assets (for example `HOW_TO_USE.md`, `README.md` and `assets/expected_output.json`).

It sits in Testing & QA, covering Unit testing, Test-driven development and Test generation. It works with Jest, JUnit, pytest and Vitest. The repository describes itself as: 385 AI skills, 77 expert agents, and 900 stdlib Python tools for every team: engineering, PM, marketing, C-level, compliance, business ops, research, and a LinkedIn toolkit… The licence is MIT.

When your agent uses it

  • Writing tests first
  • Analyzing coverage
  • Generating test stubs
  • Converting tests between Jest

Example prompts

  • “/tdd-guide”

Requirements

  • Python 3

What it can do on your machine

Read from SKILL.md and the folder at commit 4a698e8. 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

    Ships 5 files in scripts/ (Python, from the files we listed), which the agent can run.

    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

TDD Guide loads about 1.7k tokens when it runs, and up to ~11k if it reads all its reference files. Until then it costs about 62 tokens; SKILL.md has 649 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~62
When it runs · the whole SKILL.md, loaded when a task matches
~1.7k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~11k

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); the scripts in this folder are not scanned.

SKILL.md

The full file from borghei/Claude-Skills at commit 4a698e8, republished under its MIT licence (© borghei). 649 words, ~1,697 tokens.

Download SKILL.mdSave it as .claude/skills/tdd-guide/SKILL.md (or your agent's skills folder). This skill also uses 20 other files; get the full folder from GitHub.
name
tdd-guide
description
Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support. Use when writing tests first, analyzing coverage, generating test stubs, or converting tests between Jest, Pytest, JUnit, and Vitest.
license
MIT + Commons Clause
metadata.version
1.1.0
metadata.author
borghei
metadata.category
engineering
metadata.domain
testing
metadata.updated
2026-06-15
metadata.tags
tdd, test-driven-development, testing, red-green-refactor

TDD Guide

The agent guides red-green-refactor TDD workflows, generates framework-specific test stubs from requirements, parses coverage reports to identify prioritized gaps, and calculates test quality metrics including smell detection and assertion density. Supports Jest, Pytest, JUnit, Vitest, and Mocha.

Core Capabilities

  • Red-green-refactor guidance — phase validation (RED/GREEN/REFACTOR), cycle tracking, refactoring suggestions
  • Test generation — produce test cases and framework-specific stubs from user stories, acceptance criteria, and API specs
  • Coverage gap analysis — parse LCOV/JSON/XML reports, identify files below threshold, prioritize P0/P1/P2
  • Test quality metrics — cyclomatic/cognitive complexity, assertion density, isolation, naming, and test smell detection
  • Multi-framework support — convert tests and generate fixtures/mocks across Jest, Vitest, Pytest, JUnit, TestNG, Mocha, Jasmine

When to Use

  • Writing a failing test first for a new feature (test-driven development)
  • Analyzing coverage reports to find and prioritize gaps
  • Generating test stubs from requirements or API specs
  • Converting tests between frameworks or scaffolding fixtures/mocks
  • Assessing test quality and detecting smells before merge

Clarify First

Before generating tests or analyzing coverage, confirm these inputs. If any is unknown or vague, ASK — do not assume:

  • Framework & language — Jest / Vitest / Pytest / JUnit / Mocha (changes the generated stubs and any conversion)
  • Task — generate from requirements / analyze coverage / guide a red-green-refactor cycle / convert tests (selects the tool)
  • Source input — the user story / acceptance criteria, or the coverage report (LCOV/JSON/XML) to parse (the script's input)

Stop rule: ask only the 2-3 that most change the output. If the user says "just draft it," proceed and list your assumptions at the top of the artifact.

Quick Start

bash
# Generate test cases from requirements (Python API)
from test_generator import TestGenerator, TestFramework
gen = TestGenerator(framework=TestFramework.PYTEST, language="python")
cases = gen.generate_from_requirements(requirements)

# Analyze coverage gaps from LCOV report
from coverage_analyzer import CoverageAnalyzer
analyzer = CoverageAnalyzer()
analyzer.parse_coverage_report(content, "lcov")
gaps = analyzer.identify_gaps(threshold=80.0)

# Guide TDD cycle
from tdd_workflow import TDDWorkflow
wf = TDDWorkflow()
wf.start_cycle("User can reset password via email")

References

Load the reference that matches the task — keep this file lean and pull detail on demand:

  • references/workflows.md — step-by-step procedures for TDD-ing a feature, analyzing coverage gaps, and generating tests from requirements, each with validation checkpoints. Read when starting any of the three core workflows.
  • references/tool-reference.md — complete API for all eight scripts (constructors, methods, parameters, worked examples) plus the tools summary table. Read when you need exact module names or method signatures.
  • references/tdd-best-practices.md — red-green-refactor discipline, naming/structure guidelines, test quality principles, and coverage goals. Read when deciding how to write or evaluate tests.
  • references/framework-guide.md — framework selection matrix, configuration, and test patterns for TypeScript/JS, Python, and Java, with version requirements. Read when setting up or choosing a test framework.
  • references/ci-integration.md — coverage report flow, GitHub Actions examples (Jest/Pytest/JaCoCo), quality gates, and trend tracking. Read when wiring coverage and quality gates into CI.
  • references/troubleshooting-and-quality.md — anti-patterns, troubleshooting table, and success criteria. Read when tests behave unexpectedly or when defining the test-quality bar.
Show full SKILL.md (243 more words)Show less

Scope & Limitations

This skill covers:

  • Unit test generation, scaffolding, and stub creation for Jest, Pytest, JUnit, Vitest, and Mocha
  • Static coverage report parsing (LCOV, JSON/Istanbul, XML/Cobertura) with gap identification and prioritized recommendations
  • Red-green-refactor workflow guidance with phase validation and cycle tracking
  • Test quality assessment including complexity analysis, isolation scoring, naming quality, and test smell detection

This skill does NOT cover:

  • Integration, end-to-end, or performance test generation -- see senior-qa for E2E patterns and senior-devops for load testing
  • Runtime test execution or live coverage measurement -- scripts perform static analysis only; you must run your test suite externally
  • Visual/snapshot testing or browser-based test workflows -- use Playwright, Cypress, or Storybook for UI-level testing
  • Security-focused test generation (fuzz testing, penetration testing) -- see senior-security and senior-secops skills

Integration Points

SkillIntegrationData Flow
senior-qaGenerated test stubs feed into QA review workflows; QA coverage standards inform threshold settingstest_generator.py output → QA review → approved test suite
code-reviewerMetrics calculator output provides quantitative data for code review checklistsmetrics_calculator.py quality report → code review scoring
senior-fullstackScaffolded projects include test infrastructure; TDD guide generates tests for scaffolded modulesproject_scaffolder.py output → test_generator.py input
senior-devopsCoverage reports from CI pipelines are parsed by coverage analyzer; recommendations feed back into pipeline gatesCI coverage artifact → coverage_analyzer.py → pass/fail gate
senior-securityEdge-case fixtures for auth and API scenarios complement security-focused test plansfixture_generator.py auth/API edge cases → security test plan
tech-stack-evaluatorFramework detection informs stack evaluation; test quality metrics feed into technology assessmentformat_detector.py analysis → stack evaluation input

© borghei, MIT. 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 20 other files (scripts, references, assets) in engineering/tdd-guide of borghei/Claude-Skills.

  • SKILL.md
  • HOW_TO_USE.md
  • README.md
  • assets/expected_output.json
  • assets/sample_coverage_report.lcov
  • assets/sample_input_python.json
  • assets/sample_input_typescript.json
  • references/ci-integration.md
  • references/framework-guide.md
  • references/tdd-best-practices.md
  • references/tool-reference.md
  • references/troubleshooting-and-quality.md
  • references/workflows.md
  • scripts/coverage_analyzer.py
  • scripts/fixture_generator.py
  • scripts/format_detector.py
  • scripts/framework_adapter.py
  • scripts/metrics_calculator.py
  • … and 3 more

Open the folder on GitHubat commit 4a698e8

Compare with similar skills

TDD Guide 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.

TDD Guide compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
TDD Guide this skillborghei/Claude-Skills881—~1.7kAutomated safety check: PassMIT
TDD Guidealirezarezvani/claude-skills28k—~3.4kAutomated safety check: PassMIT
TDD GuideLeoYeAI/openclaw-master-skills2.2k—~1.4kAutomated safety check: PassMIT
TDD GuideaAAaqwq/AGI-Super-Team1052 repos~1.1kAutomated safety check: PassMIT
MoAI TDD Workflowmodu-ai/moai-adk1.2k—~3.1kAutomated safety check: PassApache-2.0
Code Testing Agentmicrosoft/testfx1k—~2.7kAutomated safety check: PassMIT

Similar skills

  • TDD Guide

    alirezarezvani/claude-skills

    Test-driven development skill for writing unit tests, generating test fixtures and mocks, analyzing coverage gaps, and guiding red-green-refactor workflows across Jest, Pytest, JUnit, Vitest, and…

    28k GitHub stars~3.4k tokensUpdated 1 mo ago
    Testing & QAAuto-check passed
  • TDD Guide

    LeoYeAI/openclaw-master-skills

    Test-driven development skill for writing unit tests, generating test fixtures and mocks, analyzing coverage gaps, and guiding red-green-refactor workflows across Jest, Pytest, JUnit, Vitest, and…

    2.2k GitHub stars~1.4k tokensUpdated 2 mo ago
    Testing & QAAuto-check passed
  • TDD Guide

    aAAaqwq/AGI-Super-Team

    Test-driven development workflow with test generation, coverage analysis, and multi-framework support

    105 GitHub starsUsed in 2 repos~1.1k tokens
    Testing & QAAuto-check passed
  • MoAI TDD Workflow

    modu-ai/moai-adk

    Drives test-first development through the RED, GREEN, REFACTOR cycle, with a config switch that selects between TDD and a DDD workflow for existing code.

    1.2k GitHub stars~3.1k tokensUpdated today
    Testing & QAAuto-check passed
  • Code Testing Agent

    microsoft/testfx

    Official

    Generates and writes new unit tests for any programming language — scaffolds .NET test projects, pytest suites, Vitest/Jest suites, Go test files, and JUnit suites, and configures coverage tooling…

    1k GitHub stars~2.7k tokensUpdated today
    Testing & QAAuto-check passed
  • Test Tagging

    microsoft/testfx

    Official

    Analyzes test suites in any language and tags each test with a standardized set of traits (positive, negative, critical-path, boundary, smoke, regression, integration, performance, security).

    1k GitHub stars~4.3k tokensUpdated today
    Testing & QAAuto-check passed

More from borghei/Claude-Skills

All 349 skills in this repo
  • Agents In The Team

    borghei/Claude-Skills

    Run delivery when AI coding and ops agents take tickets. An agent skill from borghei/Claude-Skills.

    881 GitHub stars~4.2k tokensUpdated today
    Auto-check passed
  • AI Content Disclosure

    borghei/Claude-Skills

    Check AI-generated marketing content and reviews for required disclosures under the EU AI Act, FTC rules and platform AI-label policies.

    881 GitHub stars~3.4k tokensUpdated today
    Auto-check passed
  • AI Prototyping

    borghei/Claude-Skills

    Idea to AI-generated prototype to customer validation to engineering handoff.

    881 GitHub stars~3.6k tokensUpdated today
    Auto-check passed
  • Analytics Engineer

    borghei/Claude-Skills

    Analytics engineering across data modeling, dbt, transformation, and semantic layers.

    881 GitHub stars~3.4k tokensUpdated today
    Auto-check passed
  • Ansoff Matrix

    borghei/Claude-Skills

    Ansoff Matrix — 4-quadrant framework for growth options: market penetration, market/product development, and diversification.

    881 GitHub stars~2.2k tokensUpdated today
    Auto-check passed
  • Brainstorm Okrs

    borghei/Claude-Skills

    OKR brainstorming and validation using the Radical Focus framework — outcome objectives, measurable key results, counter-metrics.

    881 GitHub stars~1.4k tokensUpdated today
    Auto-check passed

Categories

Questions about TDD Guide

What does TDD Guide do?

Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support. TDD Guide is an agent skill from borghei/Claude-Skills. Guide red-green-refactor TDD with test generation, coverage-gap analysis, and multi- framework support.

When should I use TDD Guide?

TDD Guide fits situations like: writing tests first; analyzing coverage; generating test stubs; converting tests between Jest.

How do I install TDD Guide in Claude Code?

Run `npx skills add borghei/Claude-Skills --skill tdd-guide -a claude-code`. Or copy the skill folder (engineering/tdd-guide in borghei/Claude-Skills) into .claude/skills/tdd-guide in your project. Claude Code loads it when a task matches its description.

How do I install TDD Guide in Codex?

Run `npx skills add borghei/Claude-Skills --skill tdd-guide -a codex`. Or copy the skill folder (engineering/tdd-guide in borghei/Claude-Skills) into .agents/skills/tdd-guide in your project. Codex loads it when a task matches its description.

Can I use TDD Guide 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 borghei/Claude-Skills --skill tdd-guide -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/tdd-guide, .gemini/skills/tdd-guide, .github/skills/tdd-guide and .opencode/skills/tdd-guide in your project.

What does TDD Guide need to run?

Going by SKILL.md and its folder, TDD Guide needs Python for the scripts in its folder. Our summary lists: Python 3.

Does TDD Guide 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 TDD Guide 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. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does TDD Guide use?

TDD Guide is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does TDD Guide use?

About 1.7k tokens (SKILL.md is roughly 6.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 9.2k tokens, read only when the agent opens those files.

What are the alternatives to TDD Guide?

Skills that share tags, products or a category with TDD Guide: TDD Guide (alirezarezvani/claude-skills, 28k stars), TDD Guide (LeoYeAI/openclaw-master-skills, 2.2k stars), TDD Guide (aAAaqwq/AGI-Super-Team, 105 stars) and MoAI TDD Workflow (modu-ai/moai-adk, 1.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains TDD Guide?

borghei (a GitHub user) maintains it in borghei/Claude-Skills, which has 881 GitHub stars. The repository holds 349 skills in this directory. The repository was last updated on October 7, 2026.

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