AgentStack
SKILL verified MIT Self-run

Expand Test Coverage

skill-zacharygcook-agent-skills-expand-test-coverage · by zacharygcook

Add meaningful tests for changed or recently committed code, run focused and full suites, and fix real implementation defects exposed by those tests. Use when asked to add tests, improve coverage, test new code, or make sure a change is well tested.

No reviews yet
0 installs
5 views
0.0% view→install

Install

$ agentstack add skill-zacharygcook-agent-skills-expand-test-coverage

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Expand Test Coverage? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Expand Test Coverage

Add tests that increase confidence in reachable behavior, not just coverage percentages.

Establish Scope

  1. Prefer the user-named files, PR, branch, or commit.
  2. Otherwise inspect git status, git diff, and git diff --cached.
  3. If the tree is clean, inspect the latest relevant commit.
  4. Read each changed file in full plus adjacent contracts and existing tests.

Before writing tests, identify the public behavior, critical invariants, error paths, state transitions, integration boundaries, and realistic edge cases. Follow the repository's existing framework, fixtures, naming, and command conventions.

Select Valuable Cases

Prioritize:

  • critical happy paths and business invariants;
  • realistic validation, authorization, not-found, and provider failures;
  • boundary values and malformed external data;
  • important state transitions and retry/idempotency behavior;
  • regression cases for confirmed bugs;
  • integration behavior where mocks would hide the risk.

Avoid tests that only restate implementation details, assert framework behavior, exercise unreachable branches, or preserve dead code. If a branch has no production path, simplify or delete it instead of inventing a test.

Iterate

  1. Write a small coherent batch.
  2. Run the narrowest relevant test command immediately.
  3. Diagnose every failure before editing.
  4. Fix production code when the test reveals a real defect; fix the test when its premise or setup is wrong.
  5. Repeat until the planned behavior passes.
  6. Run the broader affected suite, then the full suite when proportionate and practical.

Never weaken an assertion, over-mock a boundary, or change expected behavior merely to turn the suite green. When intent is ambiguous, use docs, call sites, and existing tests as evidence and report the uncertainty.

Handoff

Report:

  • behavior covered and tests added;
  • implementation bugs found and fixed;
  • focused and full commands run with results;
  • anything not run and why;
  • remaining meaningful gaps, not raw uncovered-line counts.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.