IBM
Contents Index Previous Next



Verdicts


There are two mechanisms in TTCN that provide assignment of verdicts to a test case. These mechanisms are:

A preliminary result or explicit final verdict may be associated with any TTCN statement except for the following:

The Result Variable

TTCN has a predefined test case variable, known as the result variable, called R. This variable may be used in expressions and the verdict column of a behaviour description. It is used to store preliminary results and has the following characteristics:

Preliminary Results

The value of R is changed by recording a preliminary result in the verdicts column. A preliminary result may be one of the following:

For example:

Preliminary results have an order of precedence, for example:

The table below shows how R may be changed according to the precedence rules:

Figure 55 : Calculation of the preliminary result variable R

Current
value of R
Preliminary verdict
(PASS) (INCONC) (FAIL)

none

pass

inconc

fail

pass

pass

inconc

fail

inconc

inconc

inconc

fail

fail

fail

fail

fail

Final Verdicts

Execution of a test case is terminated either by:

A final verdict may be one of the following:

If no explicit final verdict is reached, then the final verdict is the value of R. If R is still bound to the value none then this is a test case error.

The final verdict must be consistent with the value of R. For example:

The table below shows how the final verdict should be recorded according to the value of R:

Figure 56 : Final verdict

Current
value of R
Final verdict
(PASS) (INCONC) (FAIL) R

none

pass

inconc

fail

*error*

pass

pass

inconc

fail

pass

inconc

*error*

inconc

fail

inconc

fail

*error*

*error*

fail

fail


http://www.ibm.com/rational
Contents Index Previous Next