common-tdd

common-tdd is a skill for Claude Code, Codex from HoangNguyen0403/agent-skills-standard. It costs 46 tokens per session (786 once invoked), scanned A, original, MIT.

A guide to test-driven development (TDD), a way of writing a failing test before the code that makes it pass. It focuses on choosing a small test, proving a specific behavior, and checking the change in a bounded loop.

In plain words
What is it for?
Use it when adding behavior, fixing bugs, or changing tests to decide the right test level, define the regression risk, and run focused verification.
Why use it?
It helps prevent tests that only repeat existing coverage or check internal implementation details. It also makes bug fixes and new behavior easier to verify against a clear expected result.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it when adding behavior, fixing bugs, or changing tests to decide the right test level, define the regression risk, and run focused verification.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hoangnguyen0403/agent-skills-standard/common-tdd
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add HoangNguyen0403/agent-skills-standard --skill common-tdd
Clone the repo
git clone --depth 1 https://github.com/HoangNguyen0403/agent-skills-standard

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for common-tdd

README.md
[![agentmods](https://agentmods.dev/badge/skills/hoangnguyen0403/agent-skills-standard/common-tdd/github.svg)](https://agentmods.dev/skills/hoangnguyen0403/agent-skills-standard/common-tdd)
Your own site
<a href="https://agentmods.dev/skills/hoangnguyen0403/agent-skills-standard/common-tdd"><img src="https://agentmods.dev/badge/skills/hoangnguyen0403/agent-skills-standard/common-tdd/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for common-tdd

Your own site · 80×15
<a href="https://agentmods.dev/skills/hoangnguyen0403/agent-skills-standard/common-tdd"><img src="https://agentmods.dev/badge/skills/hoangnguyen0403/agent-skills-standard/common-tdd.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 786 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00046 $0.00786
Opus 5 $0.00023 $0.00393
Sonnet 5 $0.00009 $0.00157
Haiku 4.5 $0.00005 $0.00079

Measured 12d ago against content hash e46965cdbbd9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

common-tdd scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/common/common-tdd/SKILL.md · 74 lines

How it starts

The opening of the file, as written. The whole thing — 74 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Quality-First TDD

Priority: P0 (CRITICAL)

A passing test is insufficient; the test must prove an owned behavior and a distinct plausible fault.

Choose the mode

  • New behavior: strict RED -> GREEN -> REFACTOR. Do not write production code before the expected RED.
  • Legacy or bug fix: characterize only when needed, then reproduce the intended change as a failing regression (RED). Preserve unrelated existing code; do not delete it merely because it predates the test.

Before writing a test

Create one Test Intent Record per behavior/risk:

  • contract: observable contract — an application-owned result or side effect
  • fault: distinct fault — a distinct plausible regression this test would catch
  • layer: smallest honest unit, component, contract, integration, or E2E layer
  • cases: minimal distinct equivalence classes; use a parameterized test for equivalent inputs
  • command: exact focused single-run command

Reject tests that duplicate an existing fault, assert implementation detail or mock choreography, depend on time/network/order, or force a broader behavior into a unit.

Bounded loop

  1. Run configured lint/type checks, inspect nearby tests, and derive the smallest command.
  2. RED: add one intent group and run it in the foreground, sequentially, single-run mode.
  3. Classify RED as expected_red, invalid_red, unexpected_green, or verification_infra_failed. If it is unexpected_green, inspect existing coverage and remove a redundant or weak case before implementing production code.
  4. GREEN: implement only enough to satisfy expected_red; rerun the same command.
  5. REFACTOR: improve structure without changing behavior; rerun the same command.
  6. Escalate only when evidence requires it: related unit target, integration/contract target, then explicit release/full-suite gate.

Execution safety

  • Honor project timeouts; otherwise use a 120-second fallback to bound a focused command.
  • On timeout, terminate only the agent-owned process group and verify child cleanup.
  • Never watch, blanket-kill, or retry an unchanged failure. Record the new hypothesis or corrective change first.
  • Coverage is repository-configured, project-owned evidence. Without a configured threshold, report risk gaps and never add padding tests for a percentage.

Read the full file on GitHub · 74 lines

Files

What ships with it

8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 74 lines · 46 tokens per session scan A e46965cdbbd9

Subscribe to this mod's changes

common-tdd is a skill published in the GitHub repository HoangNguyen0403/agent-skills-standard (565 stars, last pushed 3d ago), licensed MIT. It adds 46 tokens to every session and 786 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.