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 条
  • [1] LTM: Scalable and Black-Box Similarity-Based Test Suite Minimization Based on Language Models
    Pan, Rongqi
    Ghaleb, Taher A.
    Briand, Lionel C.
    IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2024, 50 (11) : 3053 - 3070
  • [2] Black-Box Test Case Prioritization Using Log Analysis and Test Case Diversity
    Yu, Xiaolei
    Jia, Kai
    Hu, Wenhua
    Tian, Jing
    Xiang, Jianwen
    2023 IEEE 34TH INTERNATIONAL SYMPOSIUM ON SOFTWARE RELIABILITY ENGINEERING WORKSHOPS, ISSREW, 2023, : 186 - 191
  • [3] Test case generation based on orthogonal table for software black-box testing
    Liu, Jiu-Fu
    Yang, Zhong
    Yang, Zhen-Xing
    Sun, Lin
    Journal of Harbin Institute of Technology (New Series), 2008, 15 (03) : 365 - 368
  • [4] Black-box tree test case generation through diversity
    Shahbazi, Ali
    Panahandeh, Mahsa
    Miller, James
    AUTOMATED SOFTWARE ENGINEERING, 2018, 25 (03) : 531 - 568
  • [5] Assessing Black-box Test Case Generation Techniques for Microservices
    Giamattei, Luca
    Guerriero, Antonio
    Pietrantuono, Roberto
    Russo, Stefano
    QUALITY OF INFORMATION AND COMMUNICATIONS TECHNOLOGY, QUATIC 2022, 2022, 1621 : 46 - 60
  • [6] Black-box tree test case generation through diversity
    Ali Shahbazi
    Mahsa Panahandeh
    James Miller
    Automated Software Engineering, 2018, 25 : 531 - 568
  • [7] Requirement-based automated black-box test generation
    Tahat, LH
    Vaysburg, B
    Korel, B
    Bader, AJ
    25TH ANNUAL INTERNATIONAL COMPUTER SOFTWARE & APPLICATIONS CONFERENCE, 2001, : 489 - 495
  • [8] Multi-objective Black-Box Test Case Prioritization Based on Wordnet Distances
    van Dinten, Imara
    Zaidman, Andy
    Panichella, Annibale
    SEARCH-BASED SOFTWARE ENGINEERING, SSBSE 2023, 2024, 14415 : 101 - 107
  • [9] Tag-Based Techniques for Black-Box Test Case Prioritization for Service Testing
    Mei, Lijun
    Chan, W. K.
    Tse, T. H.
    Merkel, Robert G.
    2009 NINTH INTERNATIONAL CONFERENCE ON QUALITY SOFTWARE (QSIC 2009), 2009, : 21 - +
  • [10] Evolving a Test Oracle in Black-Box Testing
    Wang, Farn
    Wu, Jung-Hsuan
    Huang, Chung-Hao
    Chang, Kai-Hsiang
    FUNDAMENTAL APPROACHES TO SOFTWARE ENGINEERING, 2011, 6603 : 310 - 325