debug-test-failure

debug-test-failure is a skill for Claude Code, Codex from ArdurAI/ardur-agent. It costs 17 tokens per session (1,220 once invoked), scanned A, original, Apache-2.0.

A step-by-step method for diagnosing a failing automated test by treating its output as evidence before changing code. TDD, or test-driven development, is a practice of using tests to guide implementation; this tool focuses on investigating failures.

In plain words
What is it for?
Use it to inspect the complete error, isolate the failing test, compare expected and actual results, classify the failure, and look for related errors.
Why use it?
It reduces guesswork and helps identify the actual cause instead of applying a fix that only moves the failure elsewhere.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to inspect the complete error, isolate the failing test, compare expected and actual results, classify the failure, and look for related errors.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ardurai/ardur-agent/debug-test-failure
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 ArdurAI/ardur-agent --skill debug-test-failure
Clone the repo
git clone --depth 1 https://github.com/ArdurAI/ardur-agent

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 debug-test-failure

README.md
[![agentmods](https://agentmods.dev/badge/skills/ardurai/ardur-agent/debug-test-failure/github.svg)](https://agentmods.dev/skills/ardurai/ardur-agent/debug-test-failure)
Your own site
<a href="https://agentmods.dev/skills/ardurai/ardur-agent/debug-test-failure"><img src="https://agentmods.dev/badge/skills/ardurai/ardur-agent/debug-test-failure/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 debug-test-failure

Your own site · 80×15
<a href="https://agentmods.dev/skills/ardurai/ardur-agent/debug-test-failure"><img src="https://agentmods.dev/badge/skills/ardurai/ardur-agent/debug-test-failure.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 17 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,220 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.
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.00017 $0.01220
Opus 5.5 $0.00007 $0.00488
Sonnet 5.5 $0.00003 $0.00244
Haiku 4.5 $0.00002 $0.00122

Measured 1mo ago against content hash 703925695982, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

debug-test-failure 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 1mo 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.

examples/skills/debug-test-failure/SKILL.md · 119 lines

How it starts

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

Diagnosing a failing test

A failing test is a measurement, not an obstacle. Work the failure as evidence before touching any code. The goal is to know why it fails before you change anything — a fix applied without a diagnosis usually moves the failure rather than removing it.

1. Read the failure, all of it

Start from the raw output, not your memory of what the test does.

  • Find the assertion that failed and the exact line it failed on. Frameworks bury this under stack frames; the first frame inside your code is usually the one that matters.
  • Record the expected and actual values verbatim. The shape of the mismatch tells you a lot: off-by-one, wrong type, empty vs populated, None/null where a value was due, a timestamp or ordering difference.
  • Note whether it is an assertion failure, an uncaught exception, a timeout, or a panic/crash. These have different root-cause families — a timeout is rarely the same kind of bug as a wrong return value.
  • Scan for a second failure. The first error often causes the rest; fix the first and the cascade may clear.

2. Confirm it is the test you think it is

Run the single test in isolation before forming any theory:

# pick the form your runner uses
cargo test path::to::test_name -- --exact --nocapture
pytest tests/test_mod.py::test_name -x -vv
go test ./pkg -run '^TestName$' -v

Two outcomes, two meanings:

  • Fails in isolation — the bug is in the unit under test or this test's own setup. Good; you have a clean reproduction.
  • Passes in isolation, fails in the suite — this is a test-interaction bug: shared global state, leaked fixtures, ordering dependence, a database or temp file not reset between tests, or a parallel-execution race. Hunt the state that leaks across tests, not the assertion.

3. Isolate the assertion

Narrow the failure to the smallest claim that is false.

  • If the assertion compares a large structure, compare fields one at a time until you find the field that differs. Assert on that field alone.
  • If it loops, find the first iteration that fails and pin the inputs for that iteration.
  • Replace a complex expected value with an inline literal you computed by hand. If your hand-computed value also fails, the bug is in the code; if it passes, the bug was in how the test built its expectation.

Read the full file on GitHub · 119 lines

Files

What ships with it

1 file 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. 1mo ago First seen · 119 lines · 17 tokens per session scan A 703925695982

Subscribe to this mod's changes

debug-test-failure is a skill published in the GitHub repository ArdurAI/ardur-agent (2 stars, last pushed yesterday), licensed Apache-2.0. It adds 17 tokens to every session and 1,220 once invoked, about $0.0001 per session on Opus 5.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.

Related

Other skills, from other repositories