ATM: Black-box Test Case Minimization based on Test Code Similarity and Evolutionary Search

被引:9
|
作者
Pan, Rongqi [1 ]
Ghaleb, Taher A. [1 ]
Briand, Lionel [1 ,2 ]
机构
[1] Univ Ottawa, Sch EECS, Ottawa, ON, Canada
[2] Univ Luxembourg, SnT Ctr, Luxembourg, Luxembourg
基金
加拿大自然科学与工程研究理事会;
关键词
Test case minimization; Test suite reduction; Tree-based similarity; AST; Genetic algorithm; Black-box testing; GENETIC ALGORITHM; PRIORITIZATION; SELECTION;
D O I
10.1109/ICSE48619.2023.00146
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
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.
引用
收藏
页码:1700 / 1711
页数:12
相关论文
共 50 条
  • [21] Empirical Comparison of Black-box Test Case Generation Tools for RESTful APIs
    Corradini, Davide
    Zampieri, Amedeo
    Pasqua, Michele
    Ceccato, Mariano
    IEEE 21ST INTERNATIONAL WORKING CONFERENCE ON SOURCE CODE ANALYSIS AND MANIPULATION (SCAM 2021), 2021, : 226 - 236
  • [22] Black-Box Testing of Deep Neural Networks through Test Case Diversity
    Aghababaeyan, Zohreh
    Abdellatif, Manel
    Briand, Lionel
    Ramesh, S.
    Bagherzadeh, Mojtaba
    IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2023, 49 (05) : 3182 - 3204
  • [23] Verifying Agile Black-Box Test Case Quality Measurements: Expert Review
    Barraood, Samera Obaid
    Mohd, Haslina
    Baharom, Fauziah
    Almogahed, Abdullah
    IEEE ACCESS, 2023, 11 : 106987 - 107003
  • [24] Multi-Objective Black-Box Test Case Selection for System Testing
    Lachmann, Remo
    Felderer, Michael
    Nieke, Manuel
    Schulze, Sandro
    Seidl, Christoph
    Schaefer, Ina
    PROCEEDINGS OF THE 2017 GENETIC AND EVOLUTIONARY COMPUTATION CONFERENCE (GECCO'17), 2017, : 1311 - 1318
  • [25] Exploring Better Black-Box Test Case Prioritization via Log Analysis
    Chen, Zhichao
    Chen, Junjie
    Wang, Weijing
    Zhou, Jianyi
    Wang, Meng
    Chen, Xiang
    Zhou, Shan
    Wang, Jianmin
    ACM TRANSACTIONS ON SOFTWARE ENGINEERING AND METHODOLOGY, 2023, 32 (03)
  • [26] Using Machine Learning to Refine Black-Box Test Specifications and Test Suites
    Briand, Lionel C.
    Labiche, Yvan
    Bawar, Zaheer
    QSIC 2008: PROCEEDINGS OF THE EIGHTH INTERNATIONAL CONFERENCE ON QUALITY SOFTWARE, 2008, : 135 - +
  • [27] A novel test case prioritization approach for black-box testing based on K-medoids clustering
    Chen, Jinfu
    Gu, Yuechao
    Cai, Saihua
    Chen, Haibo
    Chen, Jingyi
    JOURNAL OF SOFTWARE-EVOLUTION AND PROCESS, 2024, 36 (04)
  • [28] Trajectory Optimization for Falsification: A Case Study of Vehicle Rollover Test Generation Based on Black-box Models
    Tang, Sunbochen
    Li, Nan
    Kolmanovsky, Ilya
    Girard, Anouck
    IFAC PAPERSONLINE, 2020, 53 (02): : 14279 - 14284
  • [29] Black-Box Test-Cost Reduction Based on Bayesian Network Models
    Pan, Renjian
    Zhang, Zhaobo
    Li, Xin
    Chakrabarty, Krishnendu
    Gu, Xinli
    IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN OF INTEGRATED CIRCUITS AND SYSTEMS, 2021, 40 (02) : 386 - 399
  • [30] Black-Box String Test Case Generation through a Multi-Objective Optimization
    Shahbazi, Ali
    Miller, James
    IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2016, 42 (04) : 361 - 378