Testmanager Documentation

Data Sources

Testmanager is able to connect to all data sources that are supported by the underlying PdCom library. These are, for example, real-time applications in which the PdServ library was used to make the process data available in the network. The PdServ example can be used as an example data source. See Getting Started.

Edit Mode

The testmanager is used to quickly create visualizations and user interfaces. A distinction is made between the operating mode and the editing mode. The latter is used to create, position and configure the widgets for display and operation on the corresponding tabs. The edit mode can be accessed via the global keyboard shortcut E, via the main menu Options / Edit mode or via the pen icon in the toolbar.

Widgets

The testmanager supports various widgets that can be placed on tabs. The list of widgets can be expanded using plug-ins. To create a new widget, you can open the context menu of the tab by right-clicking on an empty area and selecting a widget type.

Stylesheets

The appearance of all tabs and widgets can be influenced by stylesheets. For this purpose, there is a global stylesheet and tab-dependent and widget-dependent stylesheets. The global stylesheet can be accessed via the main menu (Options / Global stylesheet...). The stylesheets of the tabs can be accessed by right-clicking on an empty area of the tab in the context menu (Edit stylesheet...). The stylesheets of the widgets can also be accessed via the context menu or via the corresponding property (styleSheet) in the property editor.

Python Scripts

The appearance and behavior of widgets can be influenced by Python scripts. For this purpose, the test manager offers the option of storing a Python script for each widget. If a script is stored, this is indicated by a small icon () in edit mode. To edit the script of a widget, switch to edit mode (E) and open the script editor either via the context menu of a widget (Edit script...), or open the Python script window (via the main menu under Windows) and select the corresponding widget.

The upper part of the script window contains a table into which you can insert variables from the data source tree using drag-and-drop. Below this is the actual script editor.

Reacting on variable changes

If a callable object update() is defined in the Python script, it is executed each time any variable in the table changes its value. Callable objects can be functions, for example, or classes for which the __call__() method is implemented.

Accessing variables

The variables are available under the name specified in the table and have a getValue() method that returns the value.

Accessing the widget

The widget to which the script is linked can be accessed within the script via the widget variable. The following methods are defined for the widget variable:

  • setEnabled(enable) - Enables or disables the widget. enable must be an expression that can be converted to a truth value.
  • setProperty(name, value) - Sets a property of the widget. This allows properties of the widget to be changed. If the property with the name name does not exist, a so-called dynamic property is created. Stylesheets can also be influenced via this.