- Home
- Skills
- Testing & Debugging
- Regression Hunter: Diff Review and Test Design
Works with the AI Agents you already use
Regression Hunter: Diff Review and Test Design
Systematically hunt for regressions in code diffs and generate adversarial test plans to catch them.
$5
Regression Hunter: Diff Review and Test Design
Example session with this skill installed
Review this change for regressions. The retry path may run after the database has already saved the invoice. Identify only issues you can support from the code, explain uncertainty, and propose the smallest tests that would catch them.
async function createInvoice(req, db, mailer) {
const invoice = await db.insertInvoice({ customerId: req.customerId, amount: req.amount });
await mailer.sendInvoice(invoice);
return invoice;
}
async function handle(req, db, mailer) {
try {
return await createInvoice(req, db, mailer);
} catch (err) {
if (err.name === "TimeoutError") {
return await createInvoice(req, db, mailer);
}
throw err;
}
}
- Read your context and instructions
- Compiled the regression hunter
Review scope
Reviewed only the supplied functions. Database uniqueness constraints, transaction behavior, mail delivery semantics, and caller retry policy were not provided. No commands were run.
Findings
[High] A timeout after insert can create a duplicate invoice
Evidence and trigger: handle retries all TimeoutErrors. If insertInvoice committed but its response timed out, the second call inserts another invoice. No stable idempotency key or uniqueness constraint is visible in this snippet.
Impact: One customer action may create duplicate billing records.
Confidence: Medium; persistence constraints are unknown.
Suggested fix: Use a stable request idempotency key and enforce uniqueness in persistence; return the existing invoice on retry.
[Medium] A retry may send a duplicate invoice email
Evidence and trigger: sendInvoice runs for each createInvoice call. If the first send succeeds but acknowledgment or a later step times out, retry can send again. Provider idempotency is not shown.
Impact: The customer may receive duplicate notifications.
Confidence: Medium; provider behavior is unknown.
Suggested fix: Deduplicate delivery by invoice identity, for example through an idempotent outbox or provider key.
Focused test plan
| Priority | Scenario | Setup/action | Expected result |
|---|---|---|---|
| P0 | Insert commits, response times out | Persist on first call, then throw timeout; let retry run. | One invoice exists and retry returns its identity. |
| P1 | Mail accepts send, then times out | Simulate accepted delivery with lost acknowledgment. | At most one notification is delivered per invoice. |
| P1 | Concurrent retry uses same request key | Start two calls with one idempotency key. | One invoice is created; both calls resolve consistently. |
No tests were executed. Confirm database constraints and mail-provider deduplication before treating these hypotheses as confirmed.
Connects securely to your tools. The creator never sees your data.
About this skill
Regression Hunter makes code review more concrete. It maps changed inputs, state, failure paths, permissions, and compatibility assumptions; traces plausible failure mechanisms through the code you provide; and reports only actionable risks with a trigger, impact, evidence, and confidence. It then turns each credible finding into a focused test scenario designed to expose the bug before merge.
The workflow is strict about scope: it distinguishes a pasted snippet from repository context, treats suspicious patterns as prompts for investigation rather than proof, and never says tests passed unless they were actually run. It does not edit files unless you explicitly ask.
Use it with any repository-aware coding agent and the relevant diff. No scripts, integrations, or external services are required. It supports engineering review; it cannot prove software is defect-free or replace maintainers, security specialists, or execution of proposed tests.
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.
Requires a code diff or snippet to function. Cannot guarantee bug detection without full repository context. Does not perform automatic code fixes or commits.
How to use
- 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
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 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 14 days ago