Book
Unit Testing Principles, Practices, and Patterns
Vladimir Khorikov
Summary
Vladimir Khorikov gives a vocabulary for judging whether a test is actually worth keeping, built around four pillars: protection against regressions, resistance to refactoring, fast feedback, and maintainability. It isn't an introduction to testing basics. It assumes you already write tests, then pushes into mock overuse, brittle assertions, and the anti-patterns that quietly erode a suite's value over time. Examples are in C#, but the reasoning is language-agnostic, and later chapters extend the same four-pillar framework to integration and database tests.
Target Readers
- Developers who already write unit tests but suspect their suite is brittle or slow, and want a framework for diagnosing why
- Engineers who over-rely on mocks and want a principled way to decide when a mock helps versus when it just couples the test to implementation details
- Teams introducing integration tests alongside unit tests and needing a shared standard for what makes either one worth keeping
Tags
Colophon
- Publisher
- マイナビ出版
- ISBN
- 978-4839981723
- Published
- Dec 2022
- List price
- ¥4,488incl. taxMay differ from the actual selling price on Amazon
Get this book
* The link above is an advertisement via Amazon Associates.Related Books
Prerequisites
- Recommended
Clean Architecture
Robert C. Martin
Reason: Learning an architecture that controls the direction of dependencies makes you want testing principles that maximize the resulting testability. Unit Testing: Principles, Practices, and Patterns defines what a good test is, converting the loose coupling your architecture enables into testing value.
Sources
Next Books
- Recommended
Effective Software Testing
A developer's guide
Maurício Aniche
Reason: After grasping the qualities of good tests—protection against regressions, resistance to refactoring, fast feedback—you raise the question of what to test with systematic techniques like boundary analysis, equivalence partitioning, and structural testing. Case selection moves from intuition to engineering.