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

迈向放大回归测试预言的自动生成

Towards Automatic Generation of Amplified Regression Test Oracles

Alejandra Duque-Torres, Claus Klammer, Dietmar Pfahl, Stefan Fischer, Rudolf Ramler

AI总结:

针对回归测试中测试放大面临的测试预言问题,提出一种利用SUT执行时的对象状态数据放大回归测试预言的方法,初步评估表明该方法能大幅增强行为变化检测能力。

摘要:

回归测试对于确保纯代码重构不会对现有软件功能产生不利影响至关重要,但其成本可能很高,占软件维护成本的一半。自动化测试用例生成减少了工作量,但可能生成较弱的测试套件。测试放大是一种很有前景的解决方案,它通过生成额外的测试或改进现有测试来增强测试,从而提高测试覆盖率,但它面临着测试预言问题。为了解决这个问题,我们提出了一种测试预言推导方法,该方法使用被测系统(SUT)测试执行期间产生的对象状态数据来放大回归测试预言。该方法在测试执行期间监控对象状态,并将其与先前版本进行比较,以检测与SUT预期行为相关的任何变化。我们的初步评估表明,所提出的方法可以大幅增强对行为变化的检测,为其有效性提供了初步证据。

英文摘要:

Regression testing is crucial in ensuring that pure code refactoring does not adversely affect existing software functionality, but it can be expensive, accounting for half the cost of software maintenance. Automated test case generation reduces effort but may generate weak test suites. Test amplification is a promising solution that enhances tests by generating additional or improving existing ones, increasing test coverage, but it faces the test oracle problem. To address this, we propose a test oracle derivation approach that uses object state data produced during System Under Test (SUT) test execution to amplify regression test oracles. The approach monitors the object state during test execution and compares it to the previous version to detect any changes in relation to the SUT's intended behaviour. Our preliminary evaluation shows that the proposed approach can enhance the detection of behaviour changes substantially, providing initial evidence of its effectiveness.

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

↑