Automatic path test data generation based on GA-PSO

Automatic test data generation is a key issue to achieve test automation. The path test data generation is a hot point in the research field of software test investigation. The previous approaches of generating test data are mostly based on Genetic Algorithms (GA) and its improved algorithm. These approaches have tow shortcomings: one is too complex to use and difficult to set parameters. The other is weak local search and slow convergence. We propose a hybrid algorithm (GA-PSO) which combines Genetic Algorithm and Particle Swarm Optimization (PSO) in this paper. The new algorithm is proved effective by a representative test of the “triangle type of discrimination”. The experiment shows that the new algorithm has higher performance when the value of Ф is 20%.