A differential evolution based approach to generate test data for data-flow coverage

Software testing is a vital and an effort intensive phase of the software development process. Testing efficacy relies upon optimal test data from the input domain of the problem in accordance with a test adequacy criterion. Search-based evolutionary algorithms have been widely applied for automated test data generation; Genetic Algorithm (GA) and its variants being the choice of researchers. Other highly-adaptive evolutionary algorithms such as Particle Swarm Optimization (PSO) and Differential Evolution (DE) have been shown to be more accurate and efficient in comparison to GA. This paper presents a DE-based approach to generate optimal test data in accordance to the data-flow coverage test adequacy criterion. Fitness function is designed based on the concepts of dominance relations and branch distance metric. Measures such as average number of generations and average percentage coverage are collected and analysed to evaluate the performance of the proposed approach and for comparison with Random search, GA and PSO techniques on a set of benchmark programs. The results obtained have shown that the proposed DE-based approach is competent and have better performance than random search, GA and PSO with respect to optimal test data generation in accordance to the data-flow coverage test adequacy criterion.

[1]  Alessandra Gorla,et al.  Search-based data-flow test generation , 2013, 2013 IEEE 24th International Symposium on Software Reliability Engineering (ISSRE).

[2]  Mary Jean Harrold,et al.  Using Genetic Algorithms to Aid Test-Data Generation for Data-Flow Coverage , 2007, 14th Asia-Pacific Software Engineering Conference (APSEC'07).

[3]  Nigel James Tracey,et al.  A search-based automated test-data generation framework for safety-critical software , 2000 .

[4]  Moheb R. Girgis,et al.  Automatic Test Data Generation for Data Flow Testing Using a Genetic Algorithm , 2005, J. Univers. Comput. Sci..

[5]  Abazar Shamekhi,et al.  AN IMPROVED DIFFERENTIAL EVOLUTION OPTIMIZATION ALGORITHM , 2013 .

[6]  Durga Prasad Mohapatra,et al.  Automatic Test Data Generation for Data Flow Testing Using Particle Swarm Optimization , 2010, IC3.

[7]  Manju Khari,et al.  Heuristic search-based approach for automated test data generation: a survey , 2013, Int. J. Bio Inspired Comput..

[8]  Sapna Varshney,et al.  Search based software test data generation for structural testing: a perspective , 2013, SOEN.

[9]  Marc Roper,et al.  Investigating data-flow coverage of classes using evolutionary algorithms , 2007, GECCO '07.

[10]  A. Jefferson Offutt,et al.  Constraint-Based Automatic Test Data Generation , 1991, IEEE Trans. Software Eng..

[11]  Elaine J. Weyuker,et al.  Selecting Software Test Data Using Data Flow Information , 1985, IEEE Transactions on Software Engineering.

[12]  Chengying Mao,et al.  Generating Test Data for Software Structural Testing Based on Particle Swarm Optimization , 2014, Arabian Journal for Science and Engineering.

[13]  Harish Sharma,et al.  Fitness Based Self Adaptive Differential Evolution , 2013, NICSO.

[14]  Phil McMinn,et al.  Search‐based software test data generation: a survey , 2004, Softw. Test. Verification Reliab..

[15]  Lionel C. Briand,et al.  A Systematic Review of the Application and Empirical Investigation of Search-Based Test Case Generation , 2010, IEEE Transactions on Software Engineering.

[16]  Ankur Pachauri,et al.  Automated test data generation for branch testing using genetic algorithm: An improved approach using branch ordering, memory and elitism , 2013, J. Syst. Softw..

[17]  Chengying Mao,et al.  Adapting ant colony optimization to generate test data for software structural testing , 2015, Swarm Evol. Comput..

[18]  Irman Hermadi,et al.  GA-based multiple paths test data generator , 2008, Comput. Oper. Res..

[19]  Joachim Wegener,et al.  Evolutionary test environment for automatic structural testing , 2001, Inf. Softw. Technol..

[20]  Sapna Varshney,et al.  Automated Software Test Data Generation for Data Flow Dependencies using Genetic Algorithm , 2014 .

[21]  Cem Kaner,et al.  Foundations of Software Testing , 2013 .

[22]  Roy P. Pargas,et al.  Test-Data Generation Using Genetic Algorithms , 1999, Softw. Test. Verification Reliab..

[23]  R. Storn,et al.  Differential Evolution - A simple and efficient adaptive scheme for global optimization over continuous spaces , 2004 .

[24]  Sapna Varshney,et al.  Search-Based Test Data Generator for Data-Flow Dependencies Using Dominance Concepts, Branch Distance and Elitism , 2016 .