@article{8745, author = {Gordon Fraser and Andrea Arcuri and Phil McMinn}, title = {A Memetic Algorithm for Whole Test Suite Generation}, abstract = {The generation of unit-level test cases for structural code coverage is a task well-suited to Genetic Algorithms. Method call sequences must be created that construct objects, put them into the right state and then execute uncovered code. However, the generation of primitive values, such as integers and doubles, characters that appear in strings, and arrays of primitive values, are not so straightforward. Often, small local changes are required to drive the value toward the one needed to execute some target structure. However, global searches like Genetic Algorithms tend to make larger changes that are not concentrated on any particular aspect of a test case. In this paper, we extend the Genetic Algorithm behind the EvoSuite test generation tool into a Memetic Algorithm, by equipping it with several local search operators. These operators are designed to efficiently optimize primitive values and other aspects of a test suite that allow the search for test cases to function more effectively. We evaluate our operators using a rigorous experimental methodology on over 12,000 Java classes, comprising open source classes of various different kinds, including numerical applications and text processors. Our study shows that increases in branch coverage of up to 53\% are possible for an individual class in practice.}, year = {2014}, journal = {Journal of Systems and Software}, volume = {103}, pages = {311{\textendash}327}, month = {05/2015}, publisher = {University of Sheffield, Department of Computer Science}, }