paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Time to clean your test objectives

是时候清理你的测试目标了
ICSE Proceedings of the 40th International Conference on Software Engineering2018匹配度 3/10 · 该论文属于程序分析与形式验证中的测试目标剪枝,使用最弱前置条件和SMT求解,与用户关注的静态分析/形式化验证主题有间接关联;但它不涉及LLM/Agent、浮点程序分析或贝叶斯程序分析,也没有机器学习系统或Agentic程序的交叉,因此并非当前研究画像的核心方向。引用 34 inbox
Michaël Marcozzi, Sébastien Bardin, Nikolai Kosmatov, Mike Papadakis, Virgile Prevosto, Loïc Correnson
crossref: 2026-09-12

AI 速览

一句话:提出基于最弱前置条件与SMT的测试目标剪枝技术,剔除不可行和冗余的覆盖目标。

测试是检测软件缺陷的主要手段,但覆盖率准则常产生大量在实践上不可行或冗余的测试目标,例如覆盖死代码或语义等价的变异体,从而浪费测试设计与执行精力。本文提出一种可靠且可扩展的测试目标剪枝技术,将识别不可行与冗余目标归约为证明被测代码中逻辑断言的有效性。该技术被实现为工具,依赖最弱前置条件演算和SMT求解来证明断言,并构建于Frama-C验证平台之上,针对可扩展性需求进行了调优。实验表明,该剪枝能力可将程序中被瞄准的测试目标数量最多减少27%,并能扩展到20万行的真实程序,从而自动化当前测试流程中一项繁重的工作。

问题
覆盖率准则会产生大量不可行或冗余的测试目标,如死代码和语义等价变异体,损害测试套件设计的效率与精度。
方法
将测试目标剪枝归约为证明代码中逻辑断言的有效性,使用最弱前置条件演算与SMT求解实现,并基于Frama-C平台进行可扩展性调优。
评估
在真实程序上评估剪枝效果与可扩展性,实验显示目标数量最多减少27%,并可处理20万行规模的程序。
原文摘要(Abstract)

Testing is the primary approach for detecting software defects. A major challenge faced by testers lies in crafting efficient test suites, able to detect a maximum number of bugs with manageable effort. To do so, they rely on coverage criteria, which define some precise test objectives to be covered. However, many common criteria specify a significant number of objectives that occur to be infeasible or redundant in practice, like covering dead code or semantically equal mutants. Such objectives are well-known to be harmful to the design of test suites, impacting both the efficiency and precision of the tester's effort. This work introduces a sound and scalable technique to prune out a significant part of the infeasible and redundant objectives produced by a panel of white-box criteria. In a nutshell, we reduce this task to proving the validity of logical assertions in the code under test. The technique is implemented in a tool that relies on weakest-precondition calculus and SMT solving for proving the assertions. The tool is built on top of the Frama-C verification platform, which we carefully tune for our specific scalability needs. The experiments reveal that the pruning capabilities of the tool can reduce the number of targeted test objectives in a program by up to 27% and scale to real programs of 200K lines, making it possible to automate a painstaking part of their current testing process.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot4462,
  title = {Time to clean your test objectives},
  author = {Michaël Marcozzi and Sébastien Bardin and Nikolai Kosmatov and Mike Papadakis and Virgile Prevosto and Loïc Correnson},
  booktitle = {ICSE},
  year = {2018},
  doi = {10.1145/3180155.3180191}
}