Reliable Test Suites and QA Plans
Get risk-ranked test plans, executable tests, boundary mocks, coverage analysis, and evidence-based fixes for flaky tests.
Before & after
Same prompt, same agent — the only difference is the skill.
I can write tests for your cart calculation function. Generally, you'll want to test the basic cases like adding items and calculating totals. You should probably also think about edge cases, though the specifics depend on your implementation. Some people use Jest, others use Vitest or Mocha—whatever you prefer. Would it help if I also wrote tests for discounts? And do you have any special requirements like tax handling or shipping? Let me know what framework you're using and I can provide more targeted guidance.
TEST SUITE: CartTotal.test.js UNIT TESTS (5 essential cases) • Base case: 2 items × $50 = $100 ✓ • Empty cart returns $0 ✓ • Negative quantity rejected (validation layer, not calculation) ✓ • Floating point precision (three items at $33.33 each vs $100 total) ✓ • Currency override (EUR vs USD formatting, not calculation—mocked) ✓ MOCKING STRATEGY • Tax calculator: stub return 18% for all inputs • Shipping API: return fixed $9.99 per call (predictable test data) • Exchange rate service: mock at 1.1 EUR/USD (no live calls in test suite) COVERAGE GAPS • Edge case: coupon with $0 discount applied (tests discount presence, not absence) • Boundary: 99 items (tests array length limit) vs 1 item (minimum) • Integration risk: discount + tax interaction not isolated—add parameterized test FLAKY TEST PREVENTION • No floating point equality (use toBeCloseTo with 2 decimal places) • No time-dependent assertions (freeze Date.now via sinon.useFakeTimers) • No async without await or async/await syntax ESTIMATED COVERAGE: 87% (missing coupon.expiry interactions; add 2 more tests)
About this skill
Your tests pass, but production bugs still slip through. Or the same checkout test fails randomly and nobody trusts CI anymore. This skill turns code, failure logs, and coverage reports into targeted tests and fixes that expose meaningful failures.
What it does
- Chooses unit, integration, contract, or E2E tests according to where each failure can actually occur.
- Writes tests with independent expected results, boundary cases, and assertions on persisted state and side effects.
- Designs mocks around external boundaries while preserving the database, protocol, or transaction behavior under test.
- Ranks coverage gaps by business impact and missing failure behavior, rather than chasing a percentage.
- Investigates flaky tests through controlled timing, isolated state, reproducible seeds, and competing explanations.
- Defines bounded k6 or Artillery load plans and targeted security tests for authorization, injection, and data exposure.
What you get
Test code or a focused patch, plus the commands and evidence needed to verify it. For broader requests, you get a prioritized QA plan with test layers, fixtures, dependencies, acceptance criteria, and explicit limits on what has been verified.
Best for
Developers and QA engineers maintaining application test suites, reviewing release readiness, or replacing unreliable CI checks with useful regression coverage.
SKILL.md preview
---
name: reliable-test-suites-and-qa-plans
description: Writes and repairs tests, designs dependency boundaries and test architecture, and prioritizes coverage gaps using failure risks and observable outcomes. Investigates flakes and defines functional, performance, and security verification plans. Use when the user says "write tests for this", "find gaps in our coverage", "my checkout tests keep failing randomly", "design our test strategy", "what should we mock", "load test this API", or "test our authorization rules".
---
# Reliable Test Suites and QA Plans
… (sign up to view the full skill)More development skills
View all Development skills →React and Next.js Regression Test Coverage
Generate React and Next.js tests with Jest, Testing Library, MSW, and Playwright, prioritized by regression risk.
Playwright E2E Tests and Flake Repair
Build reliable Playwright tests, repair flakes from evidence, migrate suites, and configure faster, diagnosable CI.
Pre-Ship Verification for Code Changes
Before calling a code change done, Claude grades every claim by evidence, tries to break it, and reports what's verified vs assumed.
TestRail Case and CI Result Sync
Sync automated tests to TestRail cases and scoped runs with stable mappings, retry handling, and verified result counts.