Perform sanity checks

Sanity checks help you to determine whether your Scenario or individual steps of it are valid. The steps that build your Scenario are the in- and outbound messages that OSV sends and receives.

To catch potential errors as early as possible, you can already perform sanity checks while you design your Scenarios. When you transfer a Scenario to OSV, Tosca Commander automatically performs a sanity check for you.

Check your Scenario

To perform a sanity check on an OSV Scenario and all its steps, follow the steps below:

  1. In Tosca Commander, select a Scenario.

  2. Navigate to the OSV menu.

  3. Click on Sanity Check.

Check individual messages

To perform a sanity check on an individual message, follow the steps below:

  • In Tosca Commander, select a message from your Scenario. Hold CTRL to select multiple messages.

  • Right-click on the message and select OSV->Step Sanity Check from the context menu.

Sanity check on individual messages

Steps of the sanity check

The sanity check consists of multiple steps that Tosca Commander performs in the background.

Automatic changes to ActionModes

In the course of a sanity check, the system checks the ActionModes you set for message elements and automatically adapts them if necessary.

  • IN messages: ActionMode set to WaitOn.

  • OUT messages: ActionMode set to Insert.

However, the system doesn’t modify virtualization parameters during sanity checks.

Algorithms for identifying messages

Blue algorithm: If you didn't specify a dynamic identifier for inbound messages and the previous message was not outbound, the system verifies whether the ActionMode of at least one message element is set to WaitOn.

Yellow algorithm: The system verifies whether inbound messages have exactly one message element whose ActionMode is set to WaitOn and whose value is the Scenario name.

Green algorithm: The system verifies whether you used a green buffer and whether the Scenario contains at least one message element whose ActionMode is set to WaitOn and whose value is {optional}.

Specified dynamic values

If you specified values in message elements, the system checks whether

  • Brackets are specified correctly.

  • The syntax is correct.

  • The value is valid.

  • The parameters are correct.

Further checks

Additionally, the system checks whether

  • Duplicate XML attributes exist.

  • Buffer names contain only alphanumeric characters.

  • Any used buffers are either defined in the current or in the previous message.

The system deleted message elements that do not have any subordinate message elements and are no longer used.

Handle sanity check results

After the sanity check, a dialog informs you whether the sanity check was successful or not.

Successful sanity check

If the sanity check was successful, you can proceed with designing your Scenarios or transfer them to OSV.

Successful sanity check

Handle sanity check errors

If the sanity check detected an error, you have to fix it before you can deploy and run your Scenario.

To find the error, follow the steps below:

  1. In the result dialog, click Yes to see the erroneous element.

  2. Double-click the icon on the left side of the element to jump to it.

List of faulty elements

Disable sanity checks

If you disable automatic sanity checks, your Scenarios might be inconsistent and contain errors.

When you transfer Scenarios from Tosca Commander to OSV, the system automatically performs a sanity check.

To disable this default behavior, follow the steps below:

  1. Right-click on a Scenario folder or a ComponentFolder.

  2. Select Create Test configuration parameter from the context menu.

  3. Rename your parameter to SanityCheck.

  4. Enter the value False into the Value column.

This test configuration parameter (TCP) applies to the folder and all subordinate elements.