zoukankan      html  css  js  c++  java
  • 软件测试技术 hw2

     
    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];
     
     
     
  • 相关阅读:
    Java实现生产者消费者模式
    LRU结构(采用hashmap + 双向链表实现)
    自定义优先级队列PriorityQueue
    KdApiSearchDemo
    MongoDBHelper
    WebApiInvoker
    轨迹
    SignAttribute
    web api 压缩
    web api 缓存类
  • 原文地址:https://www.cnblogs.com/CindyZJT/p/5249137.html
Copyright © 2011-2022 走看看