Use the Run VisionScript Module

The Run VisionScript Module helps you overcome the limitations of the integration between Vision AI and Tricentis Tosca. With this Module you can insert VisionScript statements directly between Tricentis Tosca TestSteps.

You can find this Module at Standard modules->TBox XEngines->Vision AI.

To use this Module, follow the steps below:

  1. Drag and drop the Module Run VisionScript onto your TestCase.

  2. For the Window ModuleAttribute, specify the caption of the window that should be active when running the script.

  3. For the VisionScript ModuleAttribute, enter the VisionScript commands. To do so, refer to the Vision Script Reference.

In this example, you use the Run VisionScript Module to click on the Request Demo button.

Run VisionScript Module in a TestCase

The curly braces { and } have a special meaning in Tosca. For example, you can use them to access and pass buffer values to VisionScript: TYPE "{B[AccountNumber]}" in the 'Account' input.

However, action type commands such as typing special characters, e.g. {TAB}, can't be used directly in the Run VisionScript Module. To type these characters, you must escape the keystroke. To do so, double the { and } characters, e.g. TYPE "Joe{{TAB}}" in the 'Name' input.

The syntax for special keys in the TYPE command is slightly different to the Tosca syntax. For more information, click here.