| name | testing-strategy |
| description | Prioritizes tests based on ROI and critical user journeys. Use when: deciding test coverage, selecting test types, or budgeting effort. |
Test Strategy: ROI-Based Selection
Core Principle: Maximum Coverage, Minimum Tests
Philosophy: 10 reliable tests > 100 unmaintained tests
Quality over quantity - focus resources on high-value tests that provide maximum coverage with minimum maintenance burden.
ROI Calculation Framework
ROI Formula
ROI Score = (Business Value × User Frequency + Legal Requirement × 10 + Defect Detection)
/ (Creation Cost + Execution Cost + Maintenance Cost)
Value Components
Business Value (0-10 scale):
- 10: Revenue-critical (payment processing, checkout)
- 8-9: Core business features (user registration, data persistence)
- 5-7: Important secondary features (search, filtering)
- 2-4: Nice-to-have features (UI enhancements)
- 0-1: Cosmetic features
User Frequency (0-10 scale):
- 10: Every user, every session (authentication)
- 8-9: >80% of users regularly
- 5-7: 50-80% of users occasionally
- 2-4: <50% of users rarely
- 0-1: Edge case users only
Legal Requirement (boolean → 0 or 1):
- 1: Legally mandated (GDPR compliance, data protection)
- 0: Not legally required
Defect Detection (0-10 scale):
- 10: High likelihood of catching critical bugs
- 5-7: Moderate likelihood of catching bugs
- 0-4: Low likelihood (simple logic, well-tested patterns)
Cost Components
Test Level Cost Table: