generate-tests

Generate unit, integration, and UI tests with edge cases and mocks.

Updated Jul 24, 2024
One-click install
npx skills add https://github.com/jasonwilmot/little-riddle --skill generate-tests-jasonwilmot
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: generate-tests
Source: https://github.com/jasonwilmot/little-riddle/tree/main/.claude/skills/generate-tests
Command: npx skills add https://github.com/jasonwilmot/little-riddle --skill generate-tests-jasonwilmot

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Generating comprehensive unit, integration, and UI tests for codebases with built-in edge cases and mocks to speed up QA.

Core Features & Use Cases

  • Automated test planning: Create a structured test plan for the target code, including chosen test types and scenarios.
  • Mocking & isolation: Provide guidance on how to mock dependencies and isolate the code under test.
  • Naming conventions & coverage: Recommend test names and a coverage checklist to improve maintainability.

Quick Start

Create unit and integration tests for the target module with mocks and edge cases.

Frequently Asked Questions about generate-tests

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

FAQPage Schema
How do I generate unit tests with edge cases and mocks automatically?

To generate unit tests with edge cases and mocks automatically, you need a structured test plan that identifies dependencies to mock, checks public methods, error paths, and boundary conditions for comprehensive coverage.

What's the best way to create an automated test plan for integration tests?

The best way to create an automated test plan for integration tests is to define chosen test types, outline scenarios, and establish naming conventions to improve maintainability while ensuring comprehensive coverage of boundary conditions.

How do you mock dependencies to isolate code for testing?

To mock dependencies and isolate code for testing, identify external dependencies in the target module, replace them with mocks, and execute tests against public methods and error paths to verify behavior in isolation.

Can I generate UI tests along with unit and integration tests for the same code?

Yes, you can generate UI tests alongside unit and integration tests for the same code. The process produces test artifacts covering public methods, error paths, and boundary conditions following established naming conventions.

Why does my test coverage miss boundary conditions and error paths?

Your test coverage misses boundary conditions and error paths when the test plan lacks structured checks for edge cases. Generating tests with a coverage checklist ensures public methods, error paths, and boundary conditions are verified.

Does auto-generating tests require setting up specific test naming conventions?

Auto-generating tests does not require pre-existing naming conventions. The generation process recommends test names and provides a coverage checklist to improve maintainability and ensure test artifacts follow established conventions.