
Test Quality Analysis
This analyzes your test suite for common problems like overmocking, flaky tests, and weak assertions. It checks whether you're testing behavior instead of implementation details, flags tests with too many mocks (more than 3-4 is a smell), and helps you spot fragile selectors or race conditions. Works with Vitest, pytest, and Playwright. The coverage analysis goes beyond just percentage to look at whether critical paths and error cases are actually tested. Use it during code review or when tests keep breaking for no clear reason. The FIRST principles checklist and anti-pattern examples are genuinely helpful for spotting tests that look fine but won't catch real bugs.
- skills.sh installs
- 469
- GitHub stars
- 248
- last updated
- Aug 21, 2026
Install
$ npx -y skills add secondsky/claude-skills --skill test-quality-analysis --agent claude-codeInstalls into .claude/skills of the current project.
Files
Test Quality Analysis
Expert knowledge for analyzing and improving test quality - detecting test smells, overmocking, insufficient coverage, and testing anti-patterns.
Core Dimensions
- Correctness: Tests verify the right behavior
- Reliability: Tests are deterministic, not flaky
- Maintainability: Tests are easy to understand
- Performance: Tests run quickly
- Coverage: Tests cover critical code paths
- Isolation: Tests don't depend on external state
Test Smells
Overmocking
Problem: Mocking too many dependencies makes tests fragile.
// ❌ BAD: Overmocked
test('calculate total', () => {
const mockAdd = vi.fn(() => 10)
const mockMultiply = vi.fn(() => 20)
// Testing implementation, not behavior
})
// ✅ GOOD: Mock only external dependencies
test('calculate order total', () => {
const mockPricingAPI = vi.fn(() => ({ tax: 0.1 }))
const total = calculateTotal(order, mockPricingAPI)
expect(total).toBe(38)
})
Detection: More than 3-4 mocks, mocking pure functions, complex mock setup.
Fix: Mock only I/O boundaries (APIs, databases, filesystem).
Fragile Tests
Sponsors
Details
- Repository
- github.com/secondsky/claude-skills
- Categories
- Testing & QA, Code Review & Quality
- First seen
- Jun 3, 2026
More from secondsky/claude-skills
All 146- Api Reference Documentation465
- Tanstack Router461
- Systematic Debugging457
- Interaction Design456
- Mutation Testing456
- Api Error Handling455
- Internationalization I18n455
- Security Headers Configuration454
- Seo Optimizer453
- Sequential Thinking448
- Bun Sqlite442
- Websocket Implementation440
- Mobile App Debugging439
- Root Cause Tracing438
- App Store Deployment437
- Database Schema Design437
- Recommendation Engine437
- Seo Keyword Cluster Builder437
- Bun Sveltekit436
- Push Notification Setup436
- Drizzle Orm D1435
- Api Response Optimization434
- Api Pagination433
- Api Filtering Sorting432