TDD methodology for production-quality tests. Write tests FIRST driven by PRD, Tech Spec, Implementation Plan. Covers minimal mocking, realistic test data, strong assertions, test independence.
This Claude skill implements a comprehensive Test-Driven Development (TDD) methodology designed to produce production-quality software through a 'test-first' approach. By strictly aligning tests with PRDs, Tech Specs, and Implementation Plans, it guides developers in building a robust test pyramid—spanning unit, integration, and GUI/E2E layers. It emphasizes realistic data, minimal mocking, and strong assertions to ensure code reliability, facilitate safe refactoring, and minimize technical debt.
Use Cases
Requirement-Driven Development: Automatically generating test cases directly from PRDs and Technical Specifications to ensure 100% feature coverage before a single line of production code is written.
API Contract Testing: Establishing rigorous integration tests for backend services to validate API responses, status codes, and data schemas against technical designs.
Automated E2E User Flows: Utilizing DevTools MCP to script and execute complex frontend tests, such as multi-step login processes and dashboard navigations, ensuring a seamless user experience.
Database Integration Validation: Implementing repository-level tests with real database instances (e.g., Prisma/PostgreSQL) to verify data integrity, unique constraints, and complex query logic.
Safe Refactoring and Maintenance: Leveraging the Red-Green-Refactor cycle to modernize legacy codebases while ensuring existing functionality remains intact through a comprehensive automated test suite.
name
test-driven
description
TDD methodology for production-quality tests. Write tests FIRST driven by PRD, Tech Spec, Implementation Plan. Covers minimal mocking, realistic test data, strong assertions, test independence.
npm test # All tests
npm test -- --testPathPattern=unit # Unit only
npm test -- --testPathPattern=integration
npm run test:e2e # GUI tests
npm test -- --coverage