Interpretations of F.I.R.S.T.
Key characteristics of good unit tests: fast, independent, isolated, repeatable, self-validating, small, transparent, and written at the right time.
- Fast
Many per second - Independent
Ability to to run test cases in any order
Isolated
only one aspect per test case –> Failure reasons could better be identified - Repeatable
Execution order does no matter - Self-validating
No manual evaluation required
Small
Easy to understand, evolvable - Transparent
purpose of test case should be clear
Timely
Written before/during code