摘要
运用测试集对程序错误语句定位的算法被统称为TBFL方法。目前通行的TBFL算法一般都没有利用测试员、程序员关于测试用例和程序的先验知识,致使这些"资源"白白浪费。随机TBFL就是一类新型TBFL方法,其精神就是在随机理论的框架下,把这些先验知识和实际测试活动结合起来,从而对程序错误语句更好地定位。随机TBFL算法可以看成是这种类型算法的一般"模式",人们可以从这个一般的模式里开发出不同的算法。基于测试结果调整语句出错概率的方法就是将随机TBFL算法中关于程序、测试集的先验知识和具体测试活动分离开来,根据测试结果再先后注入人们对测试集和程序的先验知识,从而更好地定位错误语句。在一些实例上,通过把新算法和随机TBFL算法进行对比,发现新算法是可取的。提出了三个有关不同TBFL算法比较标准,从这三个标准考察,新算法在上述实例上也是良好的。
Approaches for fault localization based on test suites are now collectively called TBFL (Testing Based Fault Localization). However, current algorithms do not take advantage of the prior knowledge about test cases and program so that they waste these valuable "resources". Stochastic TBFL is a new kind of TBFL approach whose spirit is to combine the prior knowledge with actual testing activ- ities under stochastic theory, so as to locate program faults. Stochastic TBFL may be regarded as a gen- eral pattern of this approach, from which people can develop various algorithms. We separate the prior knowledge about program and test suites from actual testing activities, and according to testing results we then add the prior knowledge. This new method is called adjusting the probability of error state- ments based on testing results. Comparison to stochastic TBFL and some instances shows that our im- proved approach is feasible. Moreover, the paper proposes three standards for comparing different TBFL approaches. And from the investigation of the three standards, results of our proposed approach are also good.
出处
《计算机工程与科学》
CSCD
北大核心
2014年第5期891-899,共9页
Computer Engineering & Science
基金
国家自然科学基金资助项目(61170071)
金陵科技学院科研基金资助项目(jit-n-201305)
关键词
软件测试
错误定位
先验知识
随机方法
software test
fault localization
prior knowledge
random method