Pragmatic unit testing
summary
Argues that unit tests succeed when they maximize four measurable qualities — protection against regressions, resistance to refactoring, fast feedback and low maintenance — and defines test value as the product of those four components. Recommends output‑based (functional) tests where possible, state‑based otherwise, and restricts mocks to inter‑application boundaries because mocks are almost never a good idea for internal collaborations; shows examples of brittle tests and how to refactor them.
AI-written summary · about
chapters (29)
- 0:00Start
- 1:33About Myself
- 1:54What's the Goal of Unit Testing
- 2:46Important Benefit of Having a Unit Test Suite
- 6:53Coverage Metrics
- 8:28The Pragmatic Approach to Doing Testing
- 9:05Protection against Regressions
- 11:36Resistance to Refactoring
- 12:22False Positive
- 13:51What Causes False Positive
- 17:20Maintainability
- 18:42End-to-End Tests
- 21:38Brittle Tests
- 25:01Test Pyramid
- 26:02Types of Unit Testing
- 26:15Types of Unit Testing
- 27:27State Based Testing
- 28:08Collaboration Based Testing
- 29:49Output Based Testing
- 34:05Observable Behavior
- 34:38Observable Behavior of the Application Services Layer
- 36:20Maintaining Backward Compatibility
- 38:16Examples
- 40:47Three Types of Unit Testing
- 42:24General Guideline
- 43:36Sample Project
- 45:03Main View Model
- 48:50Overall Architecture
- 51:16Components of Available Tests








