Automated software test data generation based on ant colony algorithm

This study proposes a kind of automatic test data generation method based on ant colony algorithm. By using bit coding,a model from input domain of the software under test to ant paths of the ant colony algorithm is established.Pheromone trails of the paths depend on branch functions of program instrumentation.According to the pheromone trails,ants cooperate to find the best path to generate software test data.To improve ant path diversity and decrease the degrees of the precocity and stagnation,a mutation operator and an adaptive pheromone evaporation gene are applied.Comparative experiments are performed between ant colony algorithm and Simulated Annealing Genetic Algorithm(SAGA).Experimental results indicate that ant colony algorithm outperforms SAGA in efficiency of the test data generation.