test-generator

Generate standardized Jest or Pytest tests with Arrange-Act-Assert structure.

9|1|Updated Dec 1, 2025
One-click install
npx skills add https://github.com/benshapyro/cadre-devkit-claude --skill test-generator-benshapyro
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: test-generator
Source: https://github.com/benshapyro/cadre-devkit-claude/tree/main/skills/test-generator
Command: npx skills add https://github.com/benshapyro/cadre-devkit-claude --skill test-generator-benshapyro

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Generates high-quality tests using Jest (JavaScript/TypeScript) or Pytest (Python) following established best practices.

Core Features & Use Cases

  • Framework Support: Jest (JS/TS) and Pytest (Python)
  • Test Structure: Arrange-Act-Assert pattern, descriptive test names
  • Quality & Coverage: Negative tests, edge cases, and fixtures
  • Fixtures & Parameterization: Uses fixtures and parameterized tests to cover inputs

Quick Start

Ask Claude to generate tests for a module, e.g., "generate tests for validator.ts" or "tests for utils.py".

Frequently Asked Questions about test-generator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Jest or Pytest tests automatically?

Generate Jest or Pytest tests by providing your source code and requesting test generation. The Skill creates standardized tests following the Arrange-Act-Assert pattern, with descriptive names, mocks, fixtures, and both positive and negative test cases for comprehensive coverage.

Can I generate tests that match my project structure?

Yes. Test generation mirrors your source code structure, maintaining parallel organization. Tests follow framework-specific conventions for Jest (JavaScript/TypeScript) or Pytest (Python), ensuring consistency with your existing project layout.

What testing patterns does the generated code include?

Generated tests include fixtures, parameterized tests, mocks for dependencies, descriptive assertion messages, edge case coverage, and both positive and negative test scenarios. All tests follow Arrange-Act-Assert structure and naming conventions for readability.

Does test generation work for both JavaScript and Python projects?

Yes. The Skill generates high-quality tests for both Jest (JavaScript/TypeScript) and Pytest (Python) with framework-specific patterns, fixtures, and best practices tailored to each language's testing conventions.

How do I increase test coverage for an existing module?

Provide the module code and specify coverage gaps or areas to test. Test generation creates additional test cases including edge cases, error conditions, and parameterized scenarios to expand coverage systematically.

What's the best way to mock dependencies in generated tests?

Generated tests automatically include appropriate mocks for dependencies using framework conventions—Jest's jest.mock() or Pytest's fixtures and monkeypatch. Mocks isolate units under test and ensure consistent, repeatable test behavior.