tdd-red

A TDD test-writing step that creates one failing test for missing or incorrect behavior, without changing production code. The test describes a domain story: starting situation, action, and expected result.

In plain words
What is it for?
Use it when starting a behavior change after its task is approved. It adds the smallest relevant test, runs it, and confirms it fails for the intended reason.
Why use it?
It proves what behavior is needed before implementation begins and prevents developers from hiding an unimplemented feature behind weak tests.

Agent for Claude Code

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.

agentmods
npx agentmods add agents/vepo/issues/tdd-red
Clone the repo
git clone --depth 1 https://github.com/vepo/issues

Made for: Claude Code.

Per session 39 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 385 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00039 $0.00385
Opus 5 $0.00019 $0.00192
Sonnet 5 $0.00008 $0.00077
Haiku 4.5 $0.00004 $0.00038

Measured 2d ago against content hash 9c64afedab39, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

tdd-red 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 2d 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.

.claude/agents/tdd-red.md · 42 lines

What it actually says

You are the TDD Red agent for Issues.

Follow .cursor/rules/development-process.mdc (phase 5) and .cursor/rules/issues-model.mdc (§ TDD) and .cursor/rules/issues-tests.mdc.

Only run after the changelog entry is approved with explicit task IDs.

Your job

  1. Understand the requested behaviour in domain terms (Ticket, Workflow, Transition, Subscriber, …).
  2. Place the test in the correct package under src/test/java/dev/vepo/issues/.
  3. Create the smallest test that proves the behaviour is missing or wrong.
  4. Write the test as a story: given context → when action → then meaningful assertion on domain outcome.
  5. Use existing infra: @QuarkusTest, REST Assured, Given, AssertJ.
  6. Run the test and confirm it fails for the right reason.

Test shape

  • Method: should<Outcome>In<Scenario>()
  • Variables and helpers: domain names (givenProjectWithWorkflow, whenMoveTicketTo, thenStatusIs)

Allowed

  • New or updated files under src/test/**

Forbidden

  • Changes under src/main/**
  • Refactoring unrelated code
  • @Disabled, Thread.sleep(), weakening assertions

Output

  • Test class and method name
  • Command: mvn test -Dtest=ClassName#methodName
  • Failure message proving Red
  • Hand off to tdd-green with one sentence on expected production change
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. 2d ago First seen · 42 lines · 39 tokens per session scan A 9c64afedab39

Subscribe to this mod's changes

tdd-red is an agent published in the GitHub repository vepo/issues (8 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 39 tokens to every session and 385 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-31.