Skip to content

Generates Vitest test suites for code examples in JavaScript concept documentation pages, referencing source lines.

CCM score
64 of 100
skills.sh installs
361
GitHub stars
66.5K
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers five phases: example extraction, file structure, conversion to tests, special-case handling, and output layout
  • Includes a categorization table (testable, DOM-specific, error, conceptual, browser-only) and eight test patterns with before-and-after code
  • Enforces describe blocks that mirror documentation sections, should-prefixed test names, and From lines XX-YY source comments
  • Designed for maintainers of documentation sites who need automated checks that published code examples stay accurate

Install

$ npx -y skills add leonardomso/33-js-concepts --skill test-writer -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Skill: Test Writer for Concept Pages

Use this skill to generate comprehensive Vitest tests for all code examples in a concept documentation page. Tests verify that code examples in the documentation are accurate and work as described.

When to Use

  • After writing a new concept page
  • When adding new code examples to existing pages
  • When updating existing code examples
  • To verify documentation accuracy through automated tests
  • Before publishing to ensure all examples work correctly

Test Writing Methodology

Follow these four phases to create comprehensive tests for a concept page.

Phase 1: Code Example Extraction

Scan the concept page for all code examples and categorize them:

Details

Repository
github.com/leonardomso/33-js-concepts
Categories
Testing & QA, Frontend & UI Code, Technical Documentation
First seen
Jun 3, 2026

Questions

What does the test-writer skill do?

The test-writer skill generates comprehensive Vitest tests for code examples in JavaScript concept documentation pages. It follows project conventions and references the source lines of each example in the test comments.

How do I install the test-writer skill?

Run npx -y skills add leonardomso/33-js-concepts --skill test-writer -y in your project. After that, the test-writer skill lets the agent turn documented code examples into Vitest tests.

Which kinds of code examples does the test-writer skill turn into tests?

The test-writer skill sorts examples into testable, DOM-specific, error, conceptual and browser-only groups. It writes Vitest tests for testable and error examples, DOM tests in a separate file, and skips conceptual snippets.

Where does the test-writer skill stand in the Testing & QA category?

The test-writer skill is listed in the Testing & QA category on Claude Marketplaces, next to tdd, migrate-to-shoehorn, test-driven-development, webapp-testing and break-ui. It is aimed at checking that the examples on concept documentation pages are accurate.

More from leonardomso/33-js-concepts

All 6

Similar to Test Writer

More Testing & QA