ATM: Black-box Test Case Minimization based on Test Code Similarity and Evolutionary Search
Rongqi Pan, Taher Ahmed Ghaleb, Lionel C. Briand
Abstract
Executing large test suites is time and resource consuming, sometimes impossible, and such test suites typically contain many redundant test cases. Hence, test case (suite) minimization is used to remove redundant test cases that are unlikely to detect new faults. However, most test case minimization techniques rely on code coverage (white-box), model-based features, or requirements specifications, which are not always (entirely) accessible by test engineers. Code coverage analysis also leads to scalability issues, especially when applied to large industrial systems. Recently, a set of novel techniques was proposed, called FAST-R, relying solely on test case code for test case minimization, which appeared to be much more efficient than white-box techniques. However, it achieved a comparable low fault detection capability for Java projects, thus making its application challenging in practice. In this paper, we propose ATM (AST-based Test case Minimizer), a similarity-based, search-based test case minimization technique, taking a specific budget as input, that also relies exclusively on the source code of test cases but attempts to achieve higher fault detection through finer-grained similarity analysis and a dedicated search algorithm. ATM transforms test case code into Abstract Syntax Trees (AST) and relies on four tree-based similarity measures to apply evolutionary search, specifically genetic algorithms, to minimize test cases. We evaluated the effectiveness and efficiency of ATM on a large dataset of 16 Java projects with 661 faulty versions using three budgets ranging from 25% to 75% of test suites. ATM achieved significantly higher fault detection rates (0.82 on average), compared to FAST-R (0.61 on average) and random minimization (0.52 on average), when running only 50% of the test cases, within practically acceptable time (1.1 - 4.3 hours, on average, per project version), given that minimization is only occasionally applied when many new test cases are created (major releases). Results achieved for other budgets were consistent.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 94e41efa-a20f-4af2-98e8-21d8595467fbCited by top-tier papers4
- A First Look at the Inheritance-Induced Redundant Test ExecutionDong Jae Kim, Jinqiu Yang, Tse-Hsun ChenICSE 2024 · 2 citations
- Selecting Initial Seeds for Better JVM FuzzingTianchang Gao, Junjie Chen, Dong Wang, Yile Guo et al.ICSE 2025 · 2 citations
- Can Old Tests Do New Tricks for Resolving SWE Issues?Yang Chen, Toufique Ahmed, Reyhaneh Jabbarvand, Martin HirzelFSE 2026
- Dialect-Agnostic SQL Parsing via LLM-Based SegmentationJunwen An, Kabilan Mahathevan, Manuel RiggerSIGMOD 2026
Related papers
- Defect Prediction Guided Search-Based Software TestingAnjana Perera, Aldeida Aleti, Marcel Böhme, Burak TurhanASE 2020 · 16 citations
- Generalizing Test Cases for Comprehensive Test Scenario CoverageBinhang Qi, Yun Lin, Xinyi Weng, Chenyan Liu et al.FSE 2026 · 1 citation
- Fine-Grained Code Clone Detection with Block-Based Splitting of Abstract Syntax TreeTiancheng Hu, Zijing Xu, Yilin Fang, Yueming Wu et al.ISSTA 2023 · 18 citations
- Efficient Incremental Code Coverage Analysis for Regression Test SuitesJiale Amber Wang, Kaiyuan Wang, Pengyu NieASE 2024 · 1 citation
- Reducing Test Runtime by Transforming Test FixturesChengpeng Li, Abdelrahman Baz, August ShiASE 2024 · 1 citation
