test-writer

Generate AAA-pattern unit tests for Python and JavaScript functions and classes.

4|Updated Dec 31, 2025
One-click install
npx skills add https://github.com/dudusoar/skillOS --skill test-writer-dudusoar
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: test-writer
Source: https://github.com/dudusoar/skillOS/tree/main/.claude/skills/test-writer
Command: npx skills add https://github.com/dudusoar/skillOS --skill test-writer-dudusoar

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Writing comprehensive unit tests after every change is tedious and error-prone. test-writer automates the creation of well-structured tests for functions and classes, enabling fast, reliable test coverage.

Core Features & Use Cases

  • Analyzes a function or class to identify relevant test cases, including edge cases and error conditions.
  • Generates test files that follow the AAA pattern and support multiple frameworks (pytest, unittest, jest).
  • Creates scaffolding for fixtures, mocks, and parameterized tests, accelerating regression testing across projects.
  • Use Cases: after implementing a new function, refactoring a class, or kicking off testing in a new module, generate a complete test suite that is ready for refinement.

Quick Start

Generate a complete test suite for the specified module using the AAA pattern and a selected framework (pytest, unittest, or jest).

Frequently Asked Questions about test-writer

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

FAQPage Schema
How do I automatically generate unit tests for Python and JavaScript functions?

Automated unit test generation analyzes functions and classes to create test suites identifying edge cases and error conditions. It outputs ready-to-run tests for Python and JavaScript projects.

What is the AAA pattern in unit testing and how is it applied to generated tests?

The AAA pattern structures tests into Arrange, Act, and Assert sections. Generated test files apply this modular template to ensure deterministic test cases across supported frameworks.

Can I use automated test generation with pytest, unittest, and jest frameworks?

Yes, automated test generation supports pytest, unittest, and jest. It provides framework-specific templates and scaffolding for fixtures, mocks, and parameterized tests.

Does test generation create scaffolding for mocks and fixtures?

Yes, test generation creates scaffolding for fixtures, mocks, and parameterized tests. This accelerates regression testing by providing modular templates ready for refinement.

What's the best way to write unit tests after refactoring a class?

Generating unit tests after refactoring involves analyzing updated code to identify relevant test cases. This produces a complete suite with edge cases and error conditions ready for refinement.

Why do generated unit tests need to be refined after automatic creation?

Generated unit tests require refinement to satisfy specific deterministic requirements and integrate with existing documentation. The suite provides a structural baseline covering edge cases for customization.