Skip to content
Agentmart
Submit a tool

generate-test-cases

Generate a comprehensive set of manual test cases from the diff between the current branch and master.

Skill by rabihkodeih

IndexedMIT
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/rabihkodeih-generate-test-cases

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

Generate a comprehensive set of manual test cases from the diff between the current branch and master. Use when the user asks to generate, write, or produce test cases for a branch, reviews a PR and needs test coverage, or mentions "/generate-test-cases". Produces a markdown file using the project's table format (TC-N numbering with Precondition / Steps / Expected / Notes fields).

Use cases: documents, testing, writing, productivity

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. 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-test-cases

Tools it pre-approves 5

From allowed-tools in SKILL.md: the agent may use these without asking you each time.

  • Bash,
  • Read,
  • Grep,
  • Glob,
  • Write

What's inside

Skill name
generate-test-cases
Description
Generate a comprehensive set of manual test cases from the diff between the current branch and master. Use when the user asks to generate, write, or produce test cases for a branch, reviews a PR and needs test coverage, or mentions "/generate-test-cases". Produces a markdown file using the project's table format (TC-N numbering with Precondition / Steps / Expected / Notes fields).
License
MIT
Allowed tools
Bash,, Read,, Grep,, Glob,, Write
Instructions
96 lines in SKILL.md · view on GitHub

Before installing

  • Pre-approves some shell commands

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Generate Test Cases from Branch Diff

Analyze the diff between the current branch and `master`, then produce manual test cases covering every user-observable behavior the branch introduces or changes.

## Workflow

### 1. Collect the diff

```bash
git fetch origin master --quiet 2>/dev/null || true
BASE=$(git merge-base HEAD origin/master 2>/dev/null || git merge-base HEAD master)
git diff "$BASE"...HEAD --stat
git diff "$BASE"...HEAD
```

Use `git merge-base` (three-dot `...`), never a plain two-dot range, prevents noise from master advancing.

### 2. Understand the change, not just the diff

- Read every file the diff touches (not only the changed hunks). Context outside the hunk often determines the expected behavior.
- Read new files in full.
- Identify user-facing surfaces: routes, pages, components, forms, auth flows, redirects, data fetching, validation, conditional rendering, responsive behavior, localization, feature flags, error states.
- Skip: pure refactors, type-only edits, dependency bumps, tooling config without runtime impact, test-only changes.

### 3. Classify coverage dimensions

For each user-facing behavior, think through these dimensions and emit a case for each that applies:

- **Happy path**, the main successful flow
- **Preconditions**, fresh session, authenticated user, specific data state
- **URL variants**, root, with query params, with hash, deep links
- **State persistence**, reload, new tab, browser close, across navigation
- **Error / empty states**, invalid input, failed request, empty list
- **Access control**, unauthenticated redirect, role gating
- **Responsive**, mobile (~375px) and desktop (~1280px) breakpoints
- **Cross-cutting**, logout, session expiry, cookie/storage behavior, i18n

Skip dimensions that don't apply. Don't pad.

### 4. Emit test cases in the required format

Write to `<branch-name>-test-cases.md` at repo root unless the user specifies a different path. One markdown table per test case, exactly like this:

```markdown
### TC-N: <Short, specific title>

| Field            | Value                                                           |
| ---------------- | --------------------------------------------------------------- |
| **Precondition** | <Starting state>                                                |
| **Steps**        | 1. <First action>                                               |
|                  | 2. <Second action>                                              |
| **Expected**     | <Observable outcome, URL, visible text, element style, cookie> |
|                  | <Additional expected outcome on its own row>                    |
| **Notes**        | <Optional, cite code or edge case when non-obvious>            |
```

Rules:

- Number consecutively from TC-1.
- Title ≤ 60 chars, states WHAT is verified (not HOW).
- Precondition describes the starting state, not setup steps.
- Each step is a single imperative action a human tester performs.
- Expected is observable: specific URLs, exact visible text, element position/style, cookie values. Never reference internal state (Redux, React context, hooks).
- Multi-line Steps / Expected use continuation rows with an empty first cell (`|  |`), matching the project's existing test-case files if it has any.
- Omit the Notes row when there's nothing useful to say, don't leave an empty cell.

### 5. Coverage checklist

Before finalizing, confirm the file covers:

- [ ] Every new route / page (and unauthenticated access if auth-gated)
- [ ] Every new form (submit success + validation failure)
- [ ] Every new interactive element whose state/UI changes on interaction
- [ ] Auth & session flows, if auth was touched, login, logout, refresh, new tab, browser close
- [ ] URL preservation (query params + hash), if redirects were touched
- [ ] Responsive behavior for any new UI, mobile and desktop
- [ ] Integration points the diff could plausibly break

### 6. Report back in chat

After writing the file, respond with:

- File path
- Number of test cases
- Dimensions covered (e.g., "routing, auth, URL preservation, responsive")
- Dimensions deliberately skipped and why (e.g., "no forms touched, skipped validation cases")

## Anti-patterns to avoid

- Don't generate cases for unreachable code (pure utilities, type helpers).
- Don't invent behaviors the diff doesn't introduce.
- Don't write cases whose Expected is invisible to a tester.
- Don't number cases by file; number by logical user flow.
- Don't duplicate cases that differ only in trivial phrasing, consolidate.

From rabihkodeih/agentic-workflow, MIT.

More from rabihkodeih/agentic-workflow

Signals

Stars
0
Forks
0
Open issues
0
Last commit (this folder)
Sep 19, 2026 (1 month ago)

From GitHub (fetched Oct 24, 2026).

Details

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

More from rabihkodeih

Cite this page

generate-test-cases skill. Agent Mart. https://agentmart.dev/skills/rabihkodeih-generate-test-cases (last updated 2026-10-24)