Create a Claude Skill for Automated Unit, Integration & E2E Testing
Generate a Claude Skill (SKILL.md) that writes robust Vitest unit tests, React Testing Library specs, and Playwright browser journeys.
System Directive • Copy and Paste Below
You are an expert in Test-Driven Development and Claude Skill creation. Generate a specialized Claude Skill named `test-engineer` in a standard `SKILL.md` file. ### TESTING SPECIFICATIONS: - Test Stack: [TEST_LIBRARIES] (e.g. Vitest + React Testing Library + Playwright) - Target Source Directory: [SOURCE_DIR] - Coverage Threshold Target: [COVERAGE_TARGET] (e.g. 85% branch coverage) ### REQUIRED SKILL.MD PHASES: 1. **Frontmatter**: Valid `name: test-engineer` with triggers on test generation, coverage improvement, and regression suite requests. 2. **Phase 1: Component & Unit Analysis**: - Inspect module exports, prop types, pure helper functions, and error boundaries. - Identify edge cases (empty lists, null values, network failures, slow responses). 3. **Phase 2: Unit & Integration Test Generation**: - Follow Arrange-Act-Assert (AAA) pattern. - Avoid testing implementation details; test user-observable behaviors and accessible roles (`getByRole`). - Mock external network requests with MSW (Mock Service Worker). 4. **Phase 3: End-to-End Browser Journeys**: - Generate Playwright specs with resilient selectors (`getByRole`, `getByTestId`). - Test key user funnels, form submissions, and authentication session persistence. 5. **Phase 4: Test Execution & Verification**: - Run local test runner command and ensure all generated tests pass cleanly before reporting completion. Generate the full `SKILL.md` file.
Customization & Placeholders
Specify your test libraries and target coverage. Claude will output a comprehensive test engineer skill for Claude Code.
Example Input Values
Libraries: Vitest + Testing Library + Playwright, Source: ./src, Coverage: 90%.
Expected Output Structure
A complete SKILL.md specifying AAA test structure, accessible querying, MSW mocking, and Playwright E2E execution.
Automated QA & Continuous Testing
Qubenix implements continuous testing suites and regression harnesses to ensure rapid, zero-downtime software delivery.
More Prompts in Claude Development Toolkit
Generate a Production-Ready CLAUDE.md for an Existing Repository
Inspect an existing codebase and generate a comprehensive, accurate CLAUDE.md with project architecture, build commands, and coding conventions.
Create a Professional design.md Specification from Current Website
Inspect an existing web application or website and extract a complete, structured design.md with design tokens, typography, and component specs.
Create a Reusable Claude Skill for React & Next.js Development
Generate a fully conformant SKILL.md for React and Next.js development that enforces type safety, component modularity, and zero-re-render patterns.