Browse Prior Art Database

Method and apparatus for expression coverage

IP.com Disclosure Number: IPCOM000016031D
Original Publication Date: 2002-Oct-29
Included in the Prior Art Database: 2003-Jun-21
Document File: 2 page(s) / 40K

Publishing Venue

IBM

Abstract

Problem Many code coverage models are readily available (e.g., http://www.bullseye.com/webCoverage.html). Currently-used practical coverage models (such as statement coverage, and decision coverage) are weak in that 100% coverage can easily be reached, yet 100% coverage does not guarantee high-quality testing. Other models, such as path coverage and define-use coverage are impractical, in that reaching high coverage or even defining the set of legal coverage tasks is very hard.

This text was extracted from a PDF file.
This is the abbreviated version, containing approximately 72% of the total text.

Page 1 of 2

Method and apparatus for expression coverage

  Problem - Many code coverage models are readily available (e.g., http://www.bullseye.com/webCoverage.html). Currently-used practical coverage models (such as statement coverage, and decision coverage) are weak in that 100% coverage can easily be reached, yet 100% coverage does not guarantee high-quality testing. Other models, such as path coverage and define-use coverage are impractical, in that reaching high coverage or even defining the set of legal coverage tasks is very hard.

Solution - We propose here two new types of coverage models, expression coverage and enumerated expression coverage. These models are both practical and stronger than existing practical models:

    Expression coverage: We want to see that every expression in the program gets more than one value.

    Enumerated expression coverage:We want to see that every expression in the program gets more than one value, if it is a normal expression, and all the values it can get, if it is enumerated. An enumerated expression is an expression in which the result control flow is conditional on the expression (if, case), or an enumerated variable or function of a single enumerated variable, or the expression is assigned to enumerated type variable. The enumerated expression coverage model includes decision coverage.

    The coverage models can be implemented using current techniques that are used to implement code coverage models. The example below shows an implementatio...