Complex conditions and the MC/DC coverage criterion

Devising test suites that maximize the number of bugs they can identify while minimizing the effort/cost of building the test suite is part of any tester’s job. The question is, what can we do about complex, lengthy if statements? Modified condition/decision coverage (MC/DC) is a good answer.

The MC/DC criterion looks at combinations of conditions, as path coverage does. However, instead of testing all possible combinations, we identify the important combinations that need to be tested. MC/DC exercises each of these conditions so that it can, independently of the other conditions, affect the outcome of the entire decision. Every possible condition of each parameter must influence the outcome at least once. (For details, read Kelly Hayhurst’s 2001 paper.)


Comments

Leave a Reply

Your email address will not be published. Required fields are marked *