Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Test Gap Filler: Write Tests That Can Actually Fail

    1

    A line can be executed by a test suite without its output ever being verified, leading to a false sense of security.

    $14

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Test Gap Filler: Write Tests That Can Actually Fail

    Test Gap Filler: Write Tests That Can Actually Fail

    Example session with this skill installed

    Check the coverage for the new payment processing logic in services/billing.ts and add tests for any gaps. Existing tests use Jest.

    • Read your context and instructions
    • Compiled the test gap filler

    Analyzed services/billing.ts. Found 3 behaviors with missing or weak assertions. Performed mutation checks for all new test cases.

    TEST GAPS: services/billing.ts
    Ran: npm test -> 12 passed, 0 failed

    BEHAVIOR MAP

    BehaviorStatusExisting test
    reject transaction if balance < amountMISSING-
    apply 2% processing fee to totalWEAKbilling.test.ts:14 (asserts mock call only)
    handle stripe-api timeout errorMISSING-

    NEW TESTS

    tests/billing.test.ts

    describe('Payment Processing Logic', () => {
      it('should throw InsufficientFundsError when balance is less than transaction amount', async () => {
        const user = { balance: 50 };
        const amount = 100;
        await expect(processPayment(user, amount)).rejects.toThrow(InsufficientFundsError);
      });
    
      it('should accurately calculate and add a 2% fee to the total charge', async () => {
        const amount = 1000;
        const result = await calculateTotal(amount);
        expect(result).toBe(1020);
      });
    });
    
    **Mutation check:** changed `billing.ts:42` from `<` to `<=` -> test FAILED as expected -> restored
    **Mutation check:** changed `billing.ts:58` from `* 1.02` to `* 1.05` -> test FAILED as expected -> restored
    

    RESULT: npm test -> 14 passed, 0 failed
    STILL UNTESTED: Real-time webhook latency (requires infrastructure-level mocking outside of unit test scope).

    Next steps

    1. Review the generated assertions in tests/billing.test.ts.
    2. Merge the new test file to increase regression safety for billing logic.
    3. Consider adding integration tests for the Stripe timeout handler.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Coverage metrics lie. A line can be executed by a test suite without its output ever being verified, leading to a false sense of security. This skill identifies behaviors that lack meaningful assertions, ranks them by business risk, and generates production-ready tests that follow your existing patterns.

    What it does

    • Map behaviors by identifying specific promises like edge cases, error paths, and side effects rather than just tracking line coverage.
    • Identify weak tests that pass regardless of logic errors, such as tests that only assert a mock was called or use vague truthy checks.
    • Rank risk gaps by prioritizing high-stakes logic like billing, auth, data migrations, and validation.
    • Generate idiomatic tests using your project's specific framework, fixtures, and naming conventions.
    • Verify test failure by performing manual mutation checks, breaking the code on purpose to ensure the new test actually catches regressions.

    How it works

    1. Analyze the environment by scanning for test configurations, CI workflows, and existing test examples to match your style.
    2. Audit behavior coverage to categorize every logic path as COVERED, WEAK, or MISSING.
    3. Execute mutation testing for every new test written, proving it fails when logic is intentionally corrupted.
    4. Run the full suite to ensure new tests do not conflict with existing logic or environmental constraints.

    Frameworks & tools

    Works with Jest, Vitest, Pytest, Go test, Cargo, RSpec, and other standard runners. It adapts to existing mock libraries and project-specific testing utilities found in the codebase.

    Why this beats prompting it yourself

    Generic prompts often produce "happy path" tests that don't assert anything meaningful or fail to follow your local architecture. This skill forces a mutation check for every test it writes, guaranteeing that the test is a valid gatekeeper for your code.

    Use cases

    • Reviewing a PR to ensure new features have sufficient assertion depth.
    • Auditing legacy modules where coverage is high but bugs still leak through.
    • Hardening financial or security-critical paths against boundary errors.
    • Converting snapshot tests or weak truthy assertions into strict functional tests.

    Known limitations

    Does not support UI/browser-based end-to-end testing frameworks that require complex external drivers. Requires access to the local test runner and configuration files to execute verification.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Testing & Debugging.

    Needs to run your test suite locally. Mutation checks make small temporary edits and restore them exactly. It writes tests only and never changes production code to make a test pass; bugs it finds are reported for you to decide on.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 18 days ago

    Software
    Git

    Permissions

    Terminal / Shell
    Read Files
    Write Files
    Listed18 days ago

    What's inside

    Frequently Asked Questions

    No. It maps behaviors to tests and marks each covered, weak or missing. A line that runs under a test but is never asserted counts as weak.

    Whatever your repo already uses, such as Jest, Vitest, pytest, Go test, cargo test or RSpec. It adds no new framework or library unless you agree.

    Yes. It reads two or three of your existing tests first and copies their file layout, fixtures and naming.

    For each new test it makes a small deliberate break in the code, confirms the test fails, then restores the code exactly. Tests that still pass are rewritten or dropped.

    No. If a new test exposes a bug, it stops and reports it with the failing test and asks before fixing anything. It never deletes or loosens existing tests.

    A single SKILL.md you install in any SKILL.md-compatible agent, such as Claude Code, Codex CLI or Cursor.

    New in Testing & Debugging