fix-loop

Automate test-driven debugging cycles to fix failing unit tests.

Updated Mar 28, 2026
One-click install
npx skills add https://github.com/akirschke15-cmd/Cato-Registry --skill fix-loop-akirschke15-cmd
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: fix-loop
Source: https://github.com/akirschke15-cmd/Cato-Registry/tree/main/.claude/skills/fix-loop
Command: npx skills add https://github.com/akirschke15-cmd/Cato-Registry --skill fix-loop-akirschke15-cmd

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It eliminates slow, guess-based debugging by driving changes through a controlled test-run/failure-analysis/fix/regression cycle until the suite is green.

Core Features & Use Cases

  • Baseline capture: Runs the full (or relevant) test subset and records passing/failing counts plus error details so the starting state is explicit.
  • Root-cause analysis: Reads failing test expectations and the source under test to identify the underlying cause (grouping related failures by cause).
  • Guardrailed fix iteration: Applies fixes to source code (not tests unless genuinely incorrect), reruns only affected tests, then runs the full suite to confirm no regressions, with a max of 3 iterations per root cause.
  • Completion validation: Verifies type safety with tsc and produces a structured summary suitable for commit messages and auditing.

Quick Start

Tell the AI which failing test name or error you’re seeing (or say “Fix all failing tests”) and it will run the suite, analyze failures, iterate targeted fixes, and confirm the full test suite is passing.

Frequently Asked Questions about fix-loop

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate fixing failing TypeScript unit tests?

You can automate fixing failing TypeScript unit tests by running a test-driven debugging cycle that captures the baseline suite, analyzes root causes, applies source-code fixes iteratively, and validates with tsc --noEmit to ensure type safety and full suite health.

What is the best way to debug failing npm tests without guessing?

The best way to debug failing npm tests without guessing is using a controlled cycle that captures baseline failures, groups them by root cause, applies source-code-first fixes, and reruns affected tests. This disciplined approach replaces guesswork with targeted regression testing and full suite validation.

Can I fix all failing tests in my suite at once?

Yes, you can fix all failing tests at once by requesting a full suite fix. The system runs the baseline suite, reads failing test expectations, groups related failures by underlying cause, applies targeted source-code fixes with a 3-iteration limit, and confirms no regressions across the entire test suite.

Does this test-driven debugging approach modify test files or source code?

This test-driven debugging approach applies fixes to source code first, not tests, unless a test is genuinely incorrect. It reads failing test expectations and the source under test to identify the underlying cause, then iterates targeted source-code fixes and reruns affected tests to confirm the fix.

What are the limitations of automated regression testing for TypeScript?

Limitations of automated regression testing here include a strict 3-iteration limit per root cause for applying fixes. If the issue persists beyond three attempts, the cycle stops, requiring manual intervention to resolve the underlying source code problem before rerunning the full test suite validation.

Why do I need tsc --noEmit validation after fixing failing tests?

You need tsc --noEmit validation after fixing failing tests to verify type safety across the codebase. Once the full test suite passes regression checks, running the TypeScript compiler without emitting output ensures source-code fixes did not introduce type errors before finalizing the commit.