arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2302.10594cs.SE
收藏

从故障触发测试失败中识别片状缺陷的重要性--以铬CI为例

The Importance of Discerning Flaky from Fault-triggering Test Failures: A Case Study on the Chromium CI

Guillaume Haben, Sarra Habchi, Mike Papadakis, Maxime Cordy, Yves Le Traon

摘要:

Flaky测试是指在同一个被测程序版本的不同执行中通过和失败的测试。他们让开发人员调查错误警报(测试失败),浪费了宝贵的开发人员时间。为了解决这个问题,已经提出了许多识别非线性测试的预测方法。虽然有希望,这些方法的实际效用仍然不清楚,因为它们还没有在一个持续集成(CI)的过程中进行评估。特别是,仍然不清楚遗漏故障的影响,即,在不同的CI周期中,将故障触发测试失败视为故障。为了填补这一空白,我们在Chromium CI中应用了最先进的片状预测方法,并检查了它们的性能。也许令人惊讶的是,我们发现,尽管高精度(99.2%)的方法,他们的应用导致许多错误错过,约76.2%的所有回归故障。为了解释这一结果,我们分析了故障触发失败,并表明,故障检测具有很强的故障揭示能力,即,它们揭示了所有回归故障的1/3以上,这表明所有方法的固有局限性,这些方法集中于识别重复测试,而不是重复测试失败。更进一步,我们构建了以故障为中心的预测方法,并通过考虑新功能对其进行优化。有趣的是,我们发现这些方法比以测试为重点的方法表现更好,MCC从0.20增加到0.42。总的来说,我们的研究结果意味着,一方面,未来的研究应该集中在预测的抗剥落测试失败,而不是抗剥落测试和需要采用更彻底的实验方法时,评估片状预测方法,另一方面。

英文摘要:

Flaky tests are tests that pass and fail on different executions of the same version of a program under test. They waste valuable developer time by making developers investigate false alerts (flaky test failures). To deal with this problem, many prediction methods that identify flaky tests have been proposed. While promising, the actual utility of these methods remains unclear since they have not been evaluated within a continuous integration (CI) process. In particular, it remains unclear what is the impact of missed faults, i.e., the consideration of fault-triggering test failures as flaky, at different CI cycles. To fill this gap, we apply state-of-the-art flakiness prediction methods at the Chromium CI and check their performance. Perhaps surprisingly, we find that, despite the high precision (99.2%) of the methods, their application leads to numerous faults missed, approximately 76.2% of all regression faults. To explain this result, we analyse the fault-triggering failures and show that flaky tests have a strong fault-revealing capability, i.e., they reveal more than 1/3 of all regression faults, indicating an inherent limitation of all methods focusing on identifying flaky tests, instead of flaky test failures. Going a step further, we build failure-focused prediction methods and optimize them by considering new features. Interestingly, we find that these methods perform better than the test-focused ones, with an MCC increasing from 0.20 to 0.42. Overall, our findings imply that on the one hand future research should focus on predicting flaky test failures instead of flaky tests and the need for adopting more thorough experimental methodologies when evaluating flakiness prediction methods, on the other.

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

↑