One-click install
npx skills add https://github.com/simonheimlicher/spx-claude --skill testing-simonheimlicher
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: testing
Source: https://github.com/simonheimlicher/spx-claude/tree/main/plugins/test/skills/testing
Command: npx skills add https://github.com/simonheimlicher/spx-claude --skill testing-simonheimlicher

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill helps teams test code without defaulting to mocks, ensuring tests demonstrate production behavior rather than implementation details.

Core Features & Use Cases

  • Guidance through the five-stage testing router to determine when mocks are appropriate and when real dependencies should be used.
  • Documentation of evidence-driven testing, exception cases for test doubles, and best practices to avoid brittle tests.
  • Use Case: A developer wants to validate a module's correctness in a real environment rather than relying on mocked collaborators.

Quick Start

Define Stage 1 evidence for your module. Decide Level 2 or 3 real dependencies. Document which exception justifies doubles if used. Implement tests that verify production behavior rather than internals.

Frequently Asked Questions about testing

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

FAQPage Schema
How do I test code without mocks to prove production behavior?

Testing without mocks involves defining stage 1 evidence for your module and deciding on level 2 or 3 real dependencies to validate production behavior. This ensures tests reflect real constraints and risk rather than mocked implementation details.

When should I use test doubles instead of real dependencies in software testing?

Test doubles should only be used when a documented exception justifies them, such as specific constraints that prevent using real dependencies. This evidence-driven testing strategy prevents brittle tests and ensures tests demonstrate actual production behavior.

What is the best way to avoid brittle tests caused by mocking implementation details?

The best way to avoid brittle tests is to follow an evidence-based testing strategy that validates production behavior using real dependencies. Defaulting to mocks is avoided unless a documented exception proves doubles are necessary for specific constraints.

How does the five-stage testing router determine my test strategy?

The five-stage testing router guides you through evidence definition to determine when mocks are appropriate versus when real dependencies should be used. It enforces documenting exception cases for test doubles, ensuring your test strategy reflects actual production risk.

What are the limitations of using mocks for validating module correctness?

Mocking limitations include creating brittle tests that validate implementation details rather than production behavior. If you rely on doubles without a documented exception, tests fail to reflect real environmental constraints and risk, reducing confidence in module correctness.