Which ONE of the following options MOST ACCURATELY describes branch testing?
A.
In branch testing, the coverage items are executable statements. The aim is to design test cases that exercise statements in the code until an acceptable level of coverage is achieved, expressed as a percentage.
B.
In branch testing, the coverage items are control flow transfers between decisions, and the aim is to design test cases to exercise flow transfers in the code until an acceptable level of coverage is achieved. Coverage is measured as the number of branches exercised by the test cases divided by the total number of branches expressed as a percentage.
C.
In branch testing, the coverage items are branches, and the aim is to design test cases to exercise branches in the code until an acceptable level of coverage is achieved. Coverage is measured as the number of branches exercised by the test cases divided by the total number of branches expressed as a percentage.
D.
In branch testing, the coverage items are executable decisions. The aim is to design test cases that exercise statements in the code until an acceptable level of coverage is achieved. Coverage is expressed as a percentage.
The Answer Is:
C
This question includes an explanation.
Explanation:
Comprehensive and Detailed In-Depth Explanation:
Branch testing is a structural testing technique that ensures each branch (decision point) in the control flow is executed at least once. The goal is to measure branch coverage, which is the number of branches exercised divided by the total number of branches.
(A) describes statement testing, not branch testing.
(B) and (D) introduce confusion between decisions and statements, whereas branch testing focuses on control flow branches.
In simple terms, branch testing checks that all possible decision outcomes (true/false) are executed, whereas statement testing only ensures that each line of code is executed.