Search-based failure discovery using testability transformations to generate pseudo-oracles

Search-based failure discovery using testability transformations to generate pseudo-oracles
复制标题

DOI:
10.1145/1569901.1570127
复制
发表时间:
2009-07
期刊:
Proceedings of the 11th Annual conference on Genetic and evolutionary computation
影响因子:
--
通讯作者:
Phil McMinn
Phil McMinn
中科院分区:
其他
文献类型:
--
作者:
Phil McMinn

文献摘要

相似文献

可测试性转换是源程序到源程序的转换,旨在提高程序的可测试性。本文介绍了一种新的方法,该方法通过生成伪先知来使用转换来提高程序的可测试性。伪先知是被测程序的替代版本,其输出可以与原始程序进行比较。这两个程序之间的输出差异可能表示原始程序中存在故障。给出了两种变换。前者可以突出显示程序中的数字不准确性和累计舍入误差,而后者可以检测多线程代码中竞争条件的存在。一旦生成了伪先知,就会应用基于搜索的测试领域的技术,以自动找出程序两个版本之间的输出差异。文中给出的实验研究结果表明,随机测试和遗传算法都能够利用伪先知自动发现程序故障。使用遗传算法,可以显式地最大化原始程序和它们的伪先知之间的差异。这允许在可观察到的故障非常明显的情况下产生测试用例,从而使测试人员能够确定潜在故障的严重性。
Testability transformations are source-to-source program transformations that are designed to improve the testability of a program. This paper introduces a novel approach in which transformations are used to improve testability of a program by generating a pseudo-oracle. A pseudo-oracle is an alternative version of a program under test whose output can be compared with the original. Differences in output between the two programs may indicate a fault in the original program. Two transformations are presented. The first can highlight numerical inaccuracies in programs and cumulative roundoff errors, whilst the second may detect the presence of race conditions in multi-threaded code. Once a pseudo-oracle is generated, techniques are applied from the field of search-based testing to automatically find differences in output between the two versions of the program. The results of an experimental study presented in the paper show that both random testing and genetic algorithms are capable of utilizing the pseudo-oracles to automatically find program failures. Using genetic algorithms it is possible to explicitly maximize the discrepancies between the original programs and their pseudo-oracles. This allows for the production of test cases where the observable failure is highly pronounced, enabling the tester to establish the seriousness of the underlying fault.