Software Quality Journal

, Volume 12, Issue 2, pp 121–136

Data Generation for Path Testing

  • Nashat Mansour
  • Miran Salame
Article

DOI: 10.1023/B:SQJO.0000024059.72478.4e

Cite this article as:
Mansour, N. & Salame, M. Software Quality Journal (2004) 12: 121. doi:10.1023/B:SQJO.0000024059.72478.4e

Abstract

We present two stochastic search algorithms for generating test cases that execute specified paths in a program. The two algorithms are: a simulated annealing algorithm (SA), and a genetic algorithm (GA). These algorithms are based on an optimization formulation of the path testing problem which include both integer- and real-value test cases. We empirically compare the SA and GA algorithms with each other and with a hill-climbing algorithm, Korel's algorithm (KA), for integer-value-input subject programs and compare SA and GA with each other on real-value subject programs. Our empirical work uses several subject programs with a number of paths. The results show that: (a) SA and GA are superior to KA in the number of executed paths, (b) SA tends to perform slightly better than GA in terms of the number of executed paths, and (c) GA is faster than SA; however, KA, when it succeeds in finding the solution, is the fastest.

genetic algorithmspath testingsimulated annealingsoftware testingsoftware qualitystructural testing

Copyright information

© Kluwer Academic Publishers 2004

Authors and Affiliations

  • Nashat Mansour
    • 1
  • Miran Salame
    • 1
  1. 1.Division of Computer Science and MathematicsLebanese American UniversityBeirutLebanon