Software testing ensures that a software system behaves as intended. In this paper, we identify the methods in a software system that need better testing, and propose to use production executions to improve test suites. We devise an approach called PANKTI which monitors applications as they execute in production, and then automatically generates unit tests from the collected production data. We implement our tool for Java and evaluate it on three real-world, open-source projects: a videoconferencing system, a PDF manipulation library, and an e-commerce application. We show that PANKTI is able to generate unit tests for weakly-tested methods by monitoring them in production, and that the generated tests indeed improve the quality of the test suite of the application under consideration.
翻译:软件测试可以确保软件系统的运行。 在本文中, 我们确定软件系统中需要更好的测试的方法, 并提议使用生产处决来改进测试套件。 我们设计了一种叫做 PANKTI 的方法, 用来监测生产过程中的应用, 然后自动生成从收集的生产数据中产生的单位测试。 我们为 Java 应用了我们的工具, 并在三个真实世界的开放源码项目上进行了评估: 一个视频会议系统, 一个 PDF 操作图书馆, 和一个电子商务应用程序。 我们证明 PANKTI 能够通过监测生产过程中的薄弱测试方法产生单位测试, 产生的测试确实提高了所考虑的应用测试套的质量 。