一句话:提出 HomoTR,通过度量方法同源性,为待测方法在线推荐已有测试用例。
单元测试中自动测试生成效果常不理想,测试推荐成为提升效率的可行途径。本文提出 HomoTR,通过度量待测方法与已有测试方法之间的同源性,若二者同源,则将其已有测试用例在线推荐给新方法。初步实验表明,HomoTR 能快速、有效地推荐测试用例,帮助开发者提高测试效率。系统已集成到 MoocTest 平台,可自动执行推荐用例,并可视化分支覆盖率等测试结果,便于开发者理解测试过程。
A growing number of new technologies are used in test development. Among them, automatic test generation, a promising technology to improve the efficiency of unit testing, currently performs not satisfactory in practice. Test recommendation, like code recommendation, is another feasible technology for supporting efficient unit testing and gets increasing attention. In this paper, we develop a novel system, namely HomoTR, which implements online test recommendations by measuring the homology of two methods. If the new method under test shares homology with an existing method that has test cases, HomoTR will recommend the test cases to the new method. The preliminary experiments show that HomoTR can quickly and effectively recommend test cases to help the developers improve the testing efficiency. Besides, HomoTR has been integrated into the MoocTest platform successfully, so it can also execute the recommended test cases automatically and visualize the testing results (e.g., Branch Coverage) friendly to help developers understand the process of testing. The demo video of HomoTR can be found at https://youtu.be/_227EfcUbus.
DOI 原文 ·
@inproceedings{paperbot5884,
title = {HomoTR},
author = {Chenqian Zhu and Weisong Sun and Qin Liu and Yangyang Yuan and Chunrong Fang and Yong Huang},
booktitle = {ASE},
year = {2020},
doi = {10.1145/3324884.3415296}
}