What You See Is What You Get: Attention-based Self-guided Automatic Unit Test Generation
Xin Yin, Chao Ni, Xiaodan Xu, Xiaohu Yang

TL;DR
This paper introduces AUGER, an attention-based self-guided approach for automatic unit test generation that improves defect detection confidence and error triggering efficiency by combining defect prediction with targeted test generation.
Contribution
AUGER is a novel two-stage method that integrates defect detection and error triggering, significantly enhancing test effectiveness over state-of-the-art approaches.
Findings
AUGER improves F1-score and precision in defect detection by up to 35.3% and 40.4%.
It triggers 23 to 84 more errors than existing methods.
Demonstrates good generalization on real-world datasets.
Abstract
Software defects heavily affect software's functionalities and may cause huge losses. Recently, many AI-based approaches have been proposed to detect defects, which can be divided into two categories: software defect prediction and automatic unit test generation. While these approaches have made great progress in software defect detection, they still have several limitations in practical application, including the low confidence of prediction models and the inefficiency of unit testing models. To address these limitations, we propose a WYSIWYG (i.e., What You See Is What You Get) approach: Attention-based Self-guided Automatic Unit Test GenERation (AUGER), which contains two stages: defect detection and error triggering. In the former stage, AUGER first detects the proneness of defects. Then, in the latter stage, it guides to generate unit tests for triggering such an error with the…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsIntelligent Tutoring Systems and Adaptive Learning · Educational Technology and Assessment
