Skip to content
Agentmart
Submit a tool

generate-unit-tests

Write meaningful unit tests for changed or untested behavior, including failure paths and edge cases, in the repository's existing test conventions.

Skill by ravisingh11

IndexedMIT★ 5
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/ravisingh11-generate-unit-tests

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Write meaningful unit tests for changed or untested behavior, including failure paths and edge cases, in the repository's existing test conventions. Use when coverage of a change is missing, when changed-code coverage fails, or when asked to add tests for a module.

Use cases: testing, writing

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/generate-unit-tests

What's inside

Skill name
generate-unit-tests
Description
Write meaningful unit tests for changed or untested behavior, including failure paths and edge cases, in the repository's existing test conventions. Use when coverage of a change is missing, when changed-code coverage fails, or when asked to add tests for a module.
License
MIT
Instructions
61 lines in SKILL.md · view on GitHub

Files (3)

  • SKILL.md
  • VERIFICATION.md
  • openai.yaml · agents/

SKILL.md (first lines)

# Generate Unit Tests

Add tests that would catch a real regression. Coverage percentage is an
outcome, not the goal: a test that only executes lines without asserting
behavior is not acceptable. Use `test-gap-finder` to decide *what* is
untested; this skill writes the tests.

## Inputs

- The target: a diff, a module, or the changed-code coverage report naming
  uncovered lines.
- The repository's test framework, layout, naming, and fixtures (detect from
  existing tests; never introduce a second framework).
- The behavior specification when one exists (docstrings, acceptance criteria,
  QA plans under `qa/plans/`).

## Permitted changes

- New or extended test files following the repository's conventions.
- Small test-support helpers or fixtures in the test tree.
- Production code only for testability seams that do not change behavior
  (for example, injecting a clock), and only with an explanation.

Not permitted: changing production behavior to make a test pass, deleting or
weakening existing assertions, or marking tests skipped to raise coverage.

## Method

1. List the behaviors of the target: happy path, each failure path, boundary
   values, and any concurrency or ordering assumption.
2. For each behavior, write one test that fails if the behavior is broken;
   check this by reasoning about (or briefly introducing) the breakage.
3. Prefer black-box assertions on outputs and side effects over asserting
   implementation details.
4. Keep tests deterministic: no network, real time, or shared mutable state.
5. Run the new tests and the module's existing tests.

## Stop conditions

Stop and report when the target's intended behavior is unknowable from code
and documentation (ask rather than encode a guess as a test), or when testing
requires infrastructure the repository does not provide.

## Verification

- New tests pass; the existing suite passes.
- Each new test's name states the behavior it protects.
- If the repository supplies a changed-code coverage producer and target,
  run it and meet that target; otherwise report coverage as unavailable,
  never as passed. When measured, list remaining uncovered lines with a reason.

## Outcome report

```text
Target: <module or diff>
Behaviors covered: <list, one per test>
Behaviors not covered and why: <list>
Verified: <commands run and results; coverage before/after when measured>
```

From ravisingh11/ai-software-toolkit, MIT.

More from ravisingh11/ai-software-toolkit

Signals

Stars
5
Forks
10
Open issues
0
Last commit (this folder)
Sep 27, 2026 (1 month ago)
Last release
Oct 23, 2026 (6 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from ravisingh11

Cite this page

generate-unit-tests skill. Agent Mart. https://agentmart.dev/skills/ravisingh11-generate-unit-tests (last updated 2026-10-24)