test

Generate executable unit or integration tests from spec bead Section 5 cases.

8|1|Updated Jan 21, 2024
One-click install
npx skills add https://github.com/azigler/dotfiles --skill test-azigler
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: test
Source: https://github.com/azigler/dotfiles/tree/main/agents/skills/test
Command: npx skills add https://github.com/azigler/dotfiles --skill test-azigler

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It eliminates the gap between written specs and executable test suites by converting spec-defined behaviors into real, language-conventional test files while ensuring the implementation cannot cheat with no-op stubs.

Core Features & Use Cases

  • Spec-to-test generation: Converts every Section 5 TEST: ... block from a spec bead into runnable tests with setup, execution, assertions, and rationales.
  • Contract strengthening: Adds at least five additional edge/error tests beyond the spec to cover boundary conditions, invalid inputs, concurrency, and persistence-related scenarios.
  • Delegation verification: For delegating/adapter patterns, writes delegation-assertion tests that spy on real dependencies and fail if the implementation doesn’t actually call them.
  • Path convention compliance: Places test files according to the project’s CLAUDE.md convention (or sensible language defaults) and uses one test file per module when specs cover multiple modules.
  • Strict safety on outputs: Ensures test agents write only test files and never create or modify implementation source files.

Quick Start

Generate tests for the spec bead id 'bd-1234' by creating only the conventional test files required by the project’s testing framework.

Frequently Asked Questions about test

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

FAQPage Schema
How do I generate unit tests from a specification document?

To generate unit tests from a specification document, this Skill converts spec Section 5 test cases into runnable test files with setup, execution, and assertions. It automatically adds at least five edge and error tests to strengthen contract boundaries beyond the original spec.

Can I automatically add edge case tests to my existing test suite?

Yes, you can automatically add edge case tests to your suite because this Skill augments spec-derived tests with additional coverage for boundary conditions, invalid inputs, concurrency, and persistence-related scenarios. It strengthens the overall contract by targeting these overlooked areas.

How do I prevent stubbed implementations from passing unit tests?

To prevent stubbed implementations from passing unit tests, this Skill adds delegation-spy assertions that monitor real dependencies. These assertions fail if the implementation does not actually call the required dependencies, ensuring no-op stubs cannot cheat the test suite.

Does test generation work with multi-language repositories?

Test generation works with multi-language repositories by placing test files according to conventional per-language test paths and module-scoped organization. It respects project conventions defined in CLAUDE.md or applies sensible language defaults when organizing the generated test files.

What are the limitations of automated test generation from specs?

A key limitation of automated test generation from specs is that it strictly writes only test files and never modifies implementation source code. It relies entirely on the presence and quality of Section 5 test cases in the spec bead to produce runnable assertions.