Skip to main content

Tab: Global Information

On this tab, you define general settings for the test table. These settings can be overridden by the settings of an individual test case or a test case group.

Name

Name of the test table

Example: Test_FB_xy

Description

Optional additional information

Testee

Name of the function block to be checked using the test table

Timeout

Maximum duration for the entire test

Specified as IEC time constants: TIME or LTIME

If the duration is exceeded, then the test aborts with an error and the remaining test cases are skipped.

Example: T#10s

Categories

Comma-separated list of category names

A POU to be tested can be identified with a category by means of the pragma {attribute 'testcategory' := '<category name>,<category name>'}. If the category name is specified in Excluded categories in the configuration editor of an IEC unit test, then test cases belonging to the category are excluded from the test.

Example: {attribute 'testcategory' := 'BasicTest, CTDTest'}

Test Case Timeout

Default timeout for all test cases

Specified as IEC time constants: TIME or LTIME

This value is used when a test case has not defined a timeout.

Example: T#3s

Failure mode

Global reaction of the test in case of error

Possible settings:

  • Use standard: The standard reaction currently cannot be changed and means that the test run is aborted.

  • Abort test case

  • Abort test case group

  • Abort unit test

  • Abort test run

Forces

Definition of variables to be forced

You can create a list of variables and values with entries in the Variable and Value columns. The variables are then set to the specified value in each controller cycle. Test case-related "forces" overwrite global "forces" for the same variable.

Example: PLC_PRG.countVar := 10

Invariants

A set of conditions can be defined here, which have to be tested in each controller cycle, in addition to the test of the "testee". This is useful for tests in which the environment state of the application is also relevant. If the condition is not fulfilled, then the system reacts according to Failure mode. The condition is formulated as an IEC expression with variables that can be accessed from within the application.

Example: Variable: GVL_g.resTemp, Type: :=, Value: 10, Tolerance: 2