arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2604.01518cs.SE
收藏

基准测试足够强大吗?基于突变的诊断和回归套件的增强

Probe to Generate: Program Variant-Guided Test Augmentation for Repository-Level Repair Benchmarks

Concordia University(康考迪亚大学)

Chenglin Li, Yisen Xu, Zehao Wang, Shin Hwei Tan, Tse-Hsun, Chen

AI总结:

本文提出STING框架,通过语义改变的程序变体增强回归测试,提高基准测试的可靠性。实验显示,77%的实例存在至少一个存活变体,测试覆盖率提升,修复率下降,揭示了基准测试的不足。

摘要:

由测试套件驱动的基准测试,特别是SWE-bench,已成为衡量自动化问题解决代理效果的行业标准:生成的补丁只要通过配套的回归测试即可被接受。然而,在实践中,过于薄弱的测试套件可能允许合理但语义上错误的补丁,从而夸大报告的成功率。我们引入STING,一个用于针对性测试增强的框架,利用语义改变的程序变体作为诊断压力源,以揭示并修复基准回归套件中的弱点。变体的地面真实补丁仍能通过现有测试,揭示了约束不足的行为;这些缺口则指导生成聚焦的回归测试。生成的测试仅在(i)通过地面真实补丁,(ii)在至少一个存活的变体上失败,(iii)在行为保持转换下保持有效的情况下才被保留。应用于SWE-bench Verified,STING发现77%的实例至少有一个存活变体。STING生成1,014个经过验证的测试,覆盖211个实例,将补丁区域的行和分支覆盖率分别提高了10.8%和9.5%。重新评估前10名修复代理时,使用强化的套件后,其修复率下降了4.2%-9.0%,表明大量之前通过的补丁利用了基准测试的弱点,而非忠实实现预期修复。这些结果强调,可靠的基准评估不仅取决于补丁生成,同样也取决于测试充分性。

英文摘要:

Test-based benchmarks such as SWE-bench have become a standard basis for evaluating automated issue resolution agents, deeming a patch correct if it passes a provided regression test suite. In practice, weak test suites can admit plausible but semantically incorrect patches, inflating reported agent performance. We present \tool, a test augmentation framework that uses semantically modified program variants as behavioral probes to identify and close gaps in benchmark test suites. Variants of the reference patch that survive the original tests reveal under-constrained behaviors, which then guide targeted regression test generation. Each generated test is retained only if it passes on the reference patch, fails on at least one surviving variant, and remains robust under behavior-preserving transformations. On SWE-bench Verified, 77% of instances admit at least one surviving variant. \tool generates 1,014 validated tests across 211 instances, increasing patch-region line and branch coverage by 10.8 and 9.5 percentage points. Re-evaluating the top-10 repair agents with the augmented suites reduces resolved rates by 4.2%-9.0%, showing that many previously accepted patches exploit benchmark test gaps rather than fully satisfying the intended repair semantics. These findings demonstrate that benchmark evaluation is not solely a patch-generation problem but also a test-strength problem.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑