一句话:提出一类高效的相似度测试套件缩减方法,仅用测试用例输入,在保持故障检测能力的同时大幅提升效率。
测试套件缩减旨在从大规模测试套件中选取代表性子集,以降低回归测试成本;但现有技术常依赖代码覆盖率或规约模型等大规模系统中不易获得的工件,且开销过高。本文提出一族基于相似度的高效缩减方法,结合大数据领域算法与智能启发式,寻找分布均匀的测试用例子集;方法仅需测试用例本身(源代码或命令行输入),通用性强。作者评估四种方法,包括固定选择预算 B 的版本和保证固定覆盖率的版本。结果表明,其故障检测损失与当前最优技术相当,效率却显著提升;对超过 50 万条真实测试用例,最高效方法可在 10 秒内选出 B 条用例。
Test suite reduction approaches aim at decreasing software regression testing costs by selecting a representative subset from large-size test suites. Most existing techniques are too expensive for handling modern massive systems and moreover depend on artifacts, such as code coverage metrics or specification models, that are not commonly available at large scale. We present a family of novel very efficient approaches for similaritybased test suite reduction that apply algorithms borrowed from the big data domain together with smart heuristics for finding an evenly spread subset of test cases. The approaches are very general since they only use as input the test cases themselves (test source code or command line input).We evaluate four approaches in a version that selects a fixed budget B of test cases, and also in an adequate version that does the reduction guaranteeing some fixed coverage. The results show that the approaches yield a fault detection loss comparable to state-of-the-art techniques, while providing huge gains in terms of efficiency. When applied to a suite of more than 500K real world test cases, the most efficient of the four approaches could select B test cases (for varying B values) in less than 10 seconds.