Multicondition Coverage

Multicondition Coverage includes condition coverage. Additionally, it measures if all TRUE-FALSE-combinations for the evaluation of the atomic conditions inside the decision have been tested.

Consider the following code snippet:
if ((a || b) && (c || d)) { ...
			
Limited by short-circuit evaluation, there are seven evaluation alternatives for this decision:
1: (T || _) && (T || _) = T
2: (T || _) && (F || T) = T
3: (F || T) && (T || _) = T
4: (F || T) && (F || T) = T
5: (T || _) && (F || F) = F
6: (F || T) && (F || F) = F
7: (F || F) && (_ || _) = F
For multicondition coverage it is required that each of these TRUE-FALSE-combinations is executed at least once.

For TER calculation, Testwell CTC++ takes nine measure points into account: The seven alternatives plus the overall decision being evaluated to TRUE and to FALSE.

Multicondition instrumentation is done also in assignment statement, if the expression to be assigned is a boolean expression containing && or || operators, for example:
x = (a || b) && (c || d);
Note: Multicondition coverage is available as instrumentation mode with the ctc option -i m.