TestAgent: A Multi-Agent LLM Framework for Repository-Level Unit Test Generation
Automated unit test generation is essential for maintaining software quality, yet existing LLM-based tools often struggle with limited repository-level context and rigid generation workflows. In this paper, we present TestAgent, a multi-agent tool implemented as a VS Code extension that automates the generation of high-quality unit tests using repository-level Code Knowledge Graphs. Unlike existing tools that rely on coarse-grained workflows, TestAgent emulates human testing practices by coordinating three specialized agents: a Planner to derive testing requirements, a Generator to synthesize executable code via tool-assisted retrieval, and a Reviewer to iteratively refine tests based on execution feedback. Evaluation on 1,451 methods across six Java projects demonstrates that TestAgent achieves a 92.34% line coverage, significantly outperforming baselines like EvoSuite and ChatUniTest. Furthermore, the tool successfully detects 154 real-world bugs with high precision (92.22%), demonstrating its practical utility for regression testing and bug discovery. The tool source code and demonstration are available at: \url{https://github.com/iSEngLab/TestAgent-VSCode-Extension}.
Tue 7 JulDisplayed time zone: Eastern Time (US & Canada) change
14:00 - 15:30 | Test generation 1Industry Papers / Research Papers / Journal-First Paper / Tool Demonstrations at MB 3.435 Chair(s): Fabrizio Pastore University of Luxembourg | ||
14:00 10mTalk | TestAgent: A Multi-Agent LLM Framework for Repository-Level Unit Test Generation Tool Demonstrations ye shang Nanjing University, Quanjun Zhang Nanjing University of Science and Technology, Zhengyu Zhan Nanjing University, Ke Huang Nanjing University, Chunrong Fang Nanjing University, Zhenyu Chen Nanjing University | ||
14:10 20mTalk | Just-in-Time Catching Test Generation at Meta Industry Papers Mark Harman Meta Platforms, Inc. and UCL, Matthew Becker Meta, Yifei Chen Meta, Nicholas Cochran Meta, Pouyan Ghasemi Meta, Abhishek Gulati Meta platforms, Mehrdad Honarkhah Meta, Hervé Robert Meta platforms, Jiacheng Liu Meta, Weini Liu Meta, Sreeja Thummala Meta, Xiaoning Yang Meta, Rui Xin Meta, Sophie Zeng Meta, Zac Haluza Meta Pre-print | ||
14:30 20mTalk | Understanding and Mitigating Hallucinations in Industrial LLM-based Unit Test Generation Industry Papers Yanlun Tu Ant Group, Ziyue Zhou University of Electronic Science and Technology of China, Cheng Xu Ant Group, Jingling Sun University of Electronic Science and Technology of China, Shuai Feng Ant Group, Chengyu Zhang Loughborough University | ||
14:50 20mTalk | Directed Grammar-Based Test Generation Journal-First Paper Lukas Kirschner Saarland University, Ezekiel Soremekun Singapore University of Technology and Design Link to publication DOI Pre-print | ||
15:10 20mTalk | iCoRe: An Iterative Correlation-Aware Retriever for Bug Reproduction Test Generation Research Papers JunyiWang Zhejiang University, Jialun Cao Hong Kong University of Science and Technology, Zhongxin Liu Zhejiang University Pre-print | ||