Guideline: Writing White-box Tests
Write white-box tests that validate small increments of new code that's been recently created.
Relationships
Main Description

A white-box test approach should be taken to verify a unit's internal structure. Theoretically, you should test every possible path through the code, but that isn't always possible. At the very least you should exercise every decision-to-decision path (DD-path) at least once because you are then executing all statements at least once. A decision is typically an if-statement, and a DD-path is a path between two decisions.

To get this level of test coverage, it is recommended that you choose test data so that every decision is evaluated in every possible way. 


More Information
Guidelines