软件测试技术 hw2
2016-03-07 00:12
302 查看
1. Identify the fault.
for循环的结束条件错误,少第一个元素,即:x[0]。
应该是:i >= 0。
2. If possible, identify a test case that does not execute the fault. (Reachability)
x = [], y = 2;
3. If possible, identify a test case that executes the fault, but does not result in an error state.
x = [2,2,2], y = 2;
4. If possible identify a test case that results in an error, but not a failure.
x = [2,3,5], y = 0;
1. Identify the fault.
查找数组的最后一个0, 应该从后向前遍历数组。 即: for ( int i = x.length; i >= 0; i-- )
2. If possible, identify a test case that does not execute the fault. (Reachability)
x = [];
3. If possible, identify a test case that executes the fault, but does not result in an error state.
x = [1,2,3];
4. If possible identify a test case that results in an error, but not a failure.
x = [1 , 0];
相关文章推荐
- HDU 1087 Super Jumping! Jumping! Jumping
- 代码思路跟我的不一样,感觉很好
- 7-2-图的邻接表存储-图-第7章-《数据结构》课本源码-严蔚敏吴伟民版
- android--存储
- python数据类型之字符串
- JS冒泡与阻止
- installation failed since the device possibly has stale dexed jars that don't match the current vers
- Python List 删除元素
- 安卓第七天笔记--网络编程一
- UIDatePicker
- The Engine Document of JustWeEngine
- thinking for android's animation
- ImageView 的使用
- 生成模型与判别模型
- MySQL基础语法(一)
- 语言基础:C#运算符
- ZOJ 1709 Oil Deposits(DFS)
- iOS实现书架布局样式【一些电子书的首页】
- tomcat错误之:Exception loading sessions from persistent storage java.io.EOFException
- Java微信公众平台开发(2) 微信服务器post消息体的接收