Adaptive Random Testing (ART) enhances the testing effectiveness (including fault-detection capability) of Random Testing (RT) by increasing the diversity of the random test cases throughout the input domain. Many ART algorithms have been investigated according to different criteria, such as Fixed-Size-Candidate-Set ART (FSCS) and Restricted Random Testing (RRT), and have been widely used in many practical applications. Despite its popularity, ART suffers from the problem of high computational costs during test case generation, especially as the number of test cases increases. Although a number of strategies have been proposed to enhance the ART testing efficiency, such as the forgetting strategy and the k-dimensional tree strategy, these algorithms still face some challenges, including: (1) Although these algorithms can reduce the computation time, their execution costs are still very high, especially when the number of test cases is large; and (2) To achieve low computational costs, they may sacrifice some fault-detection capability. In this paper, we propose an approach based on Approximate Nearest Neighbors (ANNs), called Locality Sensitive Hashing ART (LSH-ART). When calculating distances among different test inputs, LSH-ART identifies the approximate (not necessarily exact) nearest neighbors for candidates in an efficient way. LSH-ART attempts to balance ART testing effectiveness and efficiency.
翻译:自适应随机测试(Adaptive Random Testing, ART)通过在整个输入域中增加随机测试用例的多样性,提升了随机测试(Random Testing, RT)的测试有效性(包括故障检测能力)。根据不同的准则,研究者已对多种ART算法进行了探索,例如固定大小候选集ART(Fixed-Size-Candidate-Set ART, FSCS)和受限随机测试(Restricted Random Testing, RRT),这些算法已广泛应用于众多实际场景。尽管ART广受欢迎,但其在测试用例生成过程中面临高计算成本的问题,尤其是当测试用例数量增加时。尽管已有多种策略被提出以提升ART测试效率,例如遗忘策略和k维树策略,但这些算法仍面临一些挑战,包括:(1)虽然这些算法能减少计算时间,但其执行成本仍然很高,特别是在测试用例数量较大时;(2)为实现低计算成本,它们可能牺牲部分故障检测能力。本文提出一种基于近似最近邻(Approximate Nearest Neighbors, ANNs)的方法,称为局部敏感哈希ART(Locality Sensitive Hashing ART, LSH-ART)。在计算不同测试输入之间的距离时,LSH-ART以高效方式识别候选集的近似(而非精确)最近邻。LSH-ART旨在平衡ART的测试有效性与效率。