generate-tests

generate-tests is a skill for Claude Code from sequenzia/agent-alchemy. It costs 48 tokens per session (4,066 once invoked), scanned A, original, MIT.

A test-file generator that turns acceptance criteria or existing source code into runnable tests matching the project's test framework and conventions.

In plain words
What is it for?
Use it to create behavior-focused tests from specifications or code, including cases for normal behavior, edge cases, and errors.
Why use it?
It removes the manual work of planning test cases, finding the right test patterns, and creating test files. It also helps check behavior before implementation is complete.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool; mentions Claude Code.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the agent-alchemy-tdd-tools plugin — 5 skills, 3 agents shipped together

Good fit Use it to create behavior-focused tests from specifications or code, including cases for normal behavior, edge cases, and errors.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add sequenzia/agent-alchemy
Claude Code
/plugin install agent-alchemy-tdd-tools

Made for: Claude Code.

Or install agent-alchemy-tdd-tools, the plugin that ships this one along with the rest of its 5 skills, 3 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for generate-tests

README.md
[![agentmods](https://agentmods.dev/badge/skills/sequenzia/agent-alchemy/generate-tests.svg)](https://agentmods.dev/skills/sequenzia/agent-alchemy/generate-tests)
Your own site
<a href="https://agentmods.dev/skills/sequenzia/agent-alchemy/generate-tests"><img src="https://agentmods.dev/badge/skills/sequenzia/agent-alchemy/generate-tests.svg" alt="Measured on agentmods" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,066 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00048 $0.04066
Opus 5 $0.00024 $0.02033
Sonnet 5 $0.00010 $0.00813
Haiku 4.5 $0.00005 $0.00407

Measured 4d ago against content hash 5f89fa8f222a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

generate-tests scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

claude/tdd-tools/skills/generate-tests/SKILL.md · 525 lines

How it starts

The opening of the file, as written. The whole thing — 525 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Generate Tests Skill

Generate high-quality, behavior-driven test files from acceptance criteria or existing source code. This skill auto-detects the project's test framework, loads framework-specific patterns, and spawns test-writer agents to produce runnable test files that follow project conventions.

CRITICAL: Complete ALL 6 phases. The workflow is not complete until Phase 6: Report is finished. After completing each phase, immediately proceed to the next phase without waiting for user prompts.

Core Principles

  1. Tests before implementation -- Generated tests should initially fail (RED state) when no implementation exists, confirming they test real behavior.
  2. Behavior over implementation -- Test what the code does, not how it does it. Tests should survive refactoring.
  3. Follow project conventions -- Match the project's existing test framework, file naming, directory structure, and assertion patterns.
  4. Standalone operation -- This skill works independently. It does not require the SDD pipeline, tdd-cycle, or any other skill to function.

AskUserQuestion is MANDATORY

IMPORTANT: You MUST use the AskUserQuestion tool for ALL questions to the user. Never ask questions through regular text output.

  • Framework selection questions -> AskUserQuestion
  • Clarifying questions about scope -> AskUserQuestion
  • Confirmation questions -> AskUserQuestion

Text output should only be used for presenting information, summaries, and progress updates.


Phase 1: Parse Input

Goal: Determine the operating mode and resolve input paths.

Analyze the $ARGUMENTS to determine which mode to use:

Mode Detection

Criteria-Driven Mode -- triggered when input is:

  • A spec file path (e.g., specs/SPEC-feature.md)
  • A task ID (e.g., 5, #5, task-5)
  • A spec section reference (e.g., specs/SPEC-feature.md Section 5.1)

Code-Analysis Mode -- triggered when input is:

  • A source file path (e.g., src/utils.py, src/services/auth.ts)
  • A directory path (e.g., src/services/)

Read the full file on GitHub · 525 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 525 lines · 48 tokens per session scan A 5f89fa8f222a

Subscribe to this mod's changes

generate-tests is a skill published in the GitHub repository sequenzia/agent-alchemy (44 stars, last pushed 3mo ago), licensed MIT. It adds 48 tokens to every session and 4,066 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

verify-gates

Runs the mechanical quality gates that the arcgentic state machine requires for state transitions. Invoked indirectly by transition.sh OR directly by orchestrator agent before declaring a state transition. Use when about to call transition.sh OR when manually verifying that a round artifact meets the gate criteria.…

Arch1eSUN/Arcgentic · 75 tokens

auto-loop

TDD-based autonomous development loop with checkpoint recovery and observability changelog.

claude-world/director-mode-lite · 17 tokens

workflow

Run the complete 5-step development workflow: focus problem → prevent over-development → test-first (TDD) → document → smart commit. Use when starting a new feature, or when the user runs /workflow or asks for the full development flow.

claude-world/director-mode-lite · 52 tokens

test-runner

Test execution reference: framework detection (pytest/jest/vitest/go/cargo/junit) and correct run/coverage commands, plus failure-analysis steps. Use when running tests, analyzing test failures, or verifying coverage after code changes.

claude-world/director-mode-lite · 50 tokens

test-first

Drive one feature through a strict TDD Red-Green-Refactor cycle with checklists for each phase. Use when implementing new functionality test-first, or when the user runs /test-first.

claude-world/director-mode-lite · 42 tokens

linked-intent-dev

Guide for linked-intent development (LID). Consult for ALL code changes. Walks changes through a mode-aware six-phase workflow (HLD → LLD → EARS → intent-narrowing edge audit → tests-first → code) with mandatory stops between each phase. Bugs walk the arrow like any other change — no short-circuit. Enforces cascade…

jszmajda/lid · 87 tokens