Automated coverage calculation and test case generation

  • Authors:
  • G. C. Morrison;C. P. Inggs;W. C. Visser

  • Affiliations:
  • Stellenbosch University, Matieland, South Africa;Stellenbosch University, Matieland, South Africa;Stellenbosch University, Matieland, South Africa

  • Venue:
  • Proceedings of the South African Institute for Computer Scientists and Information Technologists Conference
  • Year:
  • 2012

Quantified Score

Hi-index 0.00

Visualization

Abstract

This article describes the use of symbolic execution, a formal method of static analysis, to calculate code coverage of a program's existing JUnit test suites. Code coverage is measured with respect to a number of test adequacy criteria, including statement coverage, branch coverage, condition coverage, method coverage, class coverage, and loop coverage. The results of the code coverage calculation is then used to automatically generate JUnit test cases to reach areas of a program that are not sufficiently covered. The level of redundancy of each test case is also calculated during coverage calculation, thereby identifying fully redundant, and partially redundant, test cases. These calculations are packaged as an Eclipse plug-in, named ATCO. ATCO can also be used to perform coverage calculation during a manual execution of a program, allowing testers to measure the effectiveness of manual testing.