If you are testing a module of code, how do you determine the level of branch coverage you have achieved?

Các đáp án

A.By taking the number of branches you have tested and dividing that by the total number of executable statements in the module
B.By taking the number of branches you have tested and dividing that by the total number of branches in the module
C.By taking the number of branches you have tested and dividing that by the total lines of code in the module
D.By taking the number of branches you have tested and dividing that by the total number of test cases you have executed for the module

Đáp án đúng

B: By taking the number of branches you have tested and dividing that by the total number of branches in the module

Giải thích

B is correct. Branch coverage looks at the number of branches tested versus the number of branches in the code under test.

Câu hỏi khác trong đề thi này