International Journal of Computer Applications |
Foundation of Computer Science (FCS), NY, USA |
Volume 67 - Number 18 |
Year of Publication: 2013 |
Authors: N. Rajasekaran, K. K. Sureshkumar, N. M. Elango |
10.5120/11493-7200 |
N. Rajasekaran, K. K. Sureshkumar, N. M. Elango . An Empirical Study of Randomized Unit Tests using Nighthawk System. International Journal of Computer Applications. 67, 18 ( April 2013), 6-10. DOI=10.5120/11493-7200
Randomized testing has been shown to be an effective method for testing software units. However, the thoroughness of randomized unit testing varies widely according to the input which is provided by the user. Such as the relative frequencies with which methods are called to be improved the thoroughness of randomized unit testing. In this paper the system, describes genetic algorithm based parameter finding for randomized unit testing that optimizes test coverage. Here the unit test data will be generated by nighthawk system. The system can be viewed as two levels, lower level and upper level. Randomized unit testing engine is a lower level, which tests a set of methods according to parameter values specified as genes in a chromosome, including parameters that encode a value reuse policy. The upper level is a genetic algorithm (GA) which uses fitness evaluation, selection, mutation and recombination of chromosomes in order to find out good values for the genes. Integrity is evaluated on the basis of test coverage and number of method calls performed. To find good parameters users can use Nighthawk and then perform with randomized unit testing based on those parameters. Many new test cases can quickly generate by randomized testing that achieve high coverage, and can continue to do so for as long as users wish to run it. In this research the test coverage results of Nighthawk are compared with manual unit testing results [6]. The Nighthawk system produced maximum test coverage results in less timing based on the genetic algorithm comparing with manual unit testing results.