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

使用大型语言模型进行软件测试:综述、图景与愿景

Software Testing with Large Language Models: Survey, Landscape, and Vision

Junjie Wang, Yuchao Huang, Chunyang Chen, Zhe Liu, Song Wang, Qing Wang

AI总结:

本文综述 102 项相关研究,从测试任务、LLM、提示工程和配套技术等方面梳理大型语言模型在软件测试中的应用,并总结挑战、机遇与未来路线图。

摘要:

预训练大型语言模型(LLM)最近已成为自然语言处理和人工智能领域的一项突破性技术,具备处理大规模数据集的能力,并在广泛任务中展现出显著性能。与此同时,软件测试是一项至关重要的工作,是确保软件产品质量与可靠性的基石。随着软件系统的范围和复杂性持续增长,对更有效软件测试技术的需求变得日益迫切,这使得该领域适合采用诸如使用 LLM 之类的创新方法。本文全面综述了 LLM 在软件测试中的应用。文章从软件测试和 LLM 两个视角分析了 102 项将 LLM 用于软件测试的相关研究。论文详细讨论了 LLM 通常被用于的软件测试任务,其中最具代表性的是测试用例准备和程序修复。文章还分析了常用的 LLM、所采用的提示工程类型,以及与这些 LLM 配合使用的配套技术。本文同时总结了这一方向上的关键挑战和潜在机遇。这项工作可作为该领域未来研究的路线图,突出潜在的探索途径,并指出当前对在软件测试中使用 LLM 的理解所存在的空白。

英文摘要:

Pre-trained large language models (LLMs) have recently emerged as a breakthrough technology in natural language processing and artificial intelligence, with the ability to handle large-scale datasets and exhibit remarkable performance across a wide range of tasks. Meanwhile, software testing is a crucial undertaking that serves as a cornerstone for ensuring the quality and reliability of software products. As the scope and complexity of software systems continue to grow, the need for more effective software testing techniques becomes increasingly urgent, making it an area ripe for innovative approaches such as the use of LLMs. This paper provides a comprehensive review of the utilization of LLMs in software testing. It analyzes 102 relevant studies that have used LLMs for software testing, from both the software testing and LLMs perspectives. The paper presents a detailed discussion of the software testing tasks for which LLMs are commonly used, among which test case preparation and program repair are the most representative. It also analyzes the commonly used LLMs, the types of prompt engineering that are employed, as well as the accompanied techniques with these LLMs. It also summarizes the key challenges and potential opportunities in this direction. This work can serve as a roadmap for future research in this area, highlighting potential avenues for exploration, and identifying gaps in our current understanding of the use of LLMs in software testing.

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

↑