Prev Next

Testpoint Editor

The Testpoint Editor is used to compose constraints for Classes and Operations. The types of constraint permitted are dependent on the selected object. For Classes, the type will always be Invariant. For operations, the type can be either Pre-Condition, Post-Condition or Line-Condition.

Invariants are evaluated by the Analyzer when any method called on an object of the selected Class type completes. Pre-conditions are evaluated at the beginning of each call to the specified operation. Post-conditions are evaluated upon completion of each call to the specified operation. Line-conditions are evaluated each time the specified line of code is executed.

An example of composing a precondition in Enterprise Architects Test Domain system.



  1. Execute > Tools > Tester > Show Testpoint Window.
  2. In the Testpoints window, double-click on a Class or Operation to display the 'Testpoint Editor' dialog.

Constraint Group fields



See also


The type of constraint for the selected Class or Operation:

  • Invariant - Evaluated after any method called on the specified Class has completed
  • Pre-Condition - Evaluated at the beginning of each call to a specific Operation
  • Post-Condition - Evaluated after completion of each call to a specific Operation
  • Line-Condition - Evaluated upon execution of a specific line of code within an Operation


For Line-Conditions only, the Line number within the specified operation upon which to evaluate the constraint.

An offset value is automatically set if the Testpoint was created using the Code Editor context menu.

Code Editor Context Menu


The constraint to be evaluated when this Testpoint is triggered. A status of pass or fail will be recorded depending upon whether this constraint condition evaluates as true or false.

Testpoint Constraints

Action on Fail

Click on the drop-down arrow and select from the three options:

  • 'Continue' - ignore failure of this constraint and continue execution
  • 'Break execution' - halt execution and display the Stack trace
  • 'Disable on fail' - do not execute the constraint again after failing once

Evaluate When

(Optional) An additional constraint which must be met before the main Testpoint Condition is evaluated, providing greater control over test coverage.

Testpoint Constraints

Trace Group fields



See also


Specifies when the trace statement (if defined) will be output. Available options are:

  • 'Fail Only' - Output trace statement only when this Testpoint condition fails
  • 'Always' - Output trace statement every time this Testpoint is evaluated


(Optional) A message to be output when this Testpoint is evaluated.

Variables currently in scope can be included in a trace statement output by prefixing the variable name with a $ token for string variables, or a @ token for primitive types such as 'int' or 'long'.

Output from a Trace Statement can be directed either to the 'Testpoints' tab of the System Output window, or to an external file, as configured by the Analyzer Script for the parent Package.

Trace Statements

Learn more