Modified Condition Decision Coverage

With Modified Condition/ Decision coverage (MCDC) every possible outcome of a condition determines at least once the outcome of the decision. This implies Condition/ Decision coverage. In other words we cover that each condition when TRUE determines a TRUE outcome of the whole decision point, and  when FALSE determines a FALSE outcome of the whole decision point.
 
MCDC guarantees:

  • That there is at least 1 test situation in which the outcome is TRUE, owing to the fact that condition A is TRUE
  • That there is at least 1 test situation in which the outcome is FALSE, owing to the fact that condition A is FALSE
  • The same goes for all other conditions in the decision point.

 
This is a thorough level of coverage, with which the following faults, for example, would be detected in the system under test:

  • There is a condition missing that should be present
  • The “AND” was wrongly implemented as an “OR”, and vice versa
  • A condition has been inverted, such as “<” instead of “>” or “≠” instead of “=”.

The big advantage of this coverage type is its efficiency: with a decision point that consists of N conditions, usually only N+1 test situations are required for MCDC. Compared with the maximum number of test situations (the complete decision table) of 2N , that is a considerable reduction, particularly if N is large (complex decision points). This combination of “thorough coverage” with “relatively few test situations” makes this coverage type a powerful weapon in the tester’s arsenal.

 
According to the definition of MCDC, every condition should determine the outcome of the decision once. Then all the other conditions in that situation should be given a value that has no influence on the outcome of the decision. This value is called the “neutral value”.
 
See the following animation for a more detailed explanation: