软件测试第三次作业
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了软件测试第三次作业相关的知识,希望对你有一定的参考价值。
为printPrimes()方法画控制流程图:
c) 针对printPrimes(),寻找一个测试用例,让响应的测试路径访问while语句开始到for语句的边t3=(n=0)(或者n=1)
d)
节点覆盖:
TR={0,1,2,3,4,5,6,7,8,9,10,11,12,13}
边覆盖:
TR={ (0,1),(1,2),(2,3),
(3,4),(4,5),(4,6),(5,6),(6,3),(3,7),(7,8),(7,9),(8,9),(9,1),(1,10),(10,11),(10,13),(11,12),(12,10)}
主路径覆盖:
TR={
[4,5,6,3,7,9,1,10,13]
[4,5,6,3,7,8,9,1,10,13]
[4,5,6,3,7,9,1,10,11,12]
[4,5,6,3,7,8,9,1,10,11,12]
[2,3,7,8,9,1,10,11,12]
[2,3,7,8,9,1,10,13]
[4,5,6,3,7,8,9,1,2]
[7,8,9,1,2,3,4,5,6]
[2,3,7,9,1,10,11,12]
[4,5,6,3,7,9,1,2]
[7,8,9,1,2,3,4,6]
[7,9,1,2,3,4,5,6]
[0,1,2,3,4,5,6]
[0,1,2,3,7,8,9]
[7,9,1,2,3,4,6]
[0,1,10,13]
[0,1,10,11,12]
[11,12,10,13]
[2,3,7,8,9,1,2]*
[3,7,8,9,1,2,3]*
[7,8,9,1,2,3,7]*
[8,9,1,2,3,7,8]*
[9,1,2,3,7,8,9]*
[1,2,3,7,8,9,1]*
[3,7,9,1,2,3]*
[7,9,1,2,3,7]*
[9,1,2,3,7,9]*
[3,4,5,6,3]*
[4,5,6,3,4]*
[5,6,3,4,5]*
[6,3,4,5,6]*
[3,4,6,3]*
[4,6,3,4]*
[6,3,4,6]*
[10,11,12,10]*
[11,12,10,11]*
[12,10,11,12]*
}
以上是关于软件测试第三次作业的主要内容,如果未能解决你的问题,请参考以下文章