Create a Scenario for a Process

Create Scenarios in a Process.

Guidelines to Create a Scenario

Follow these guidelines to create a Scenario:

Provide Specific Mock Request Data to Test

A method by which to create a Scenario is to provide only the specific JSON data model that contains the Process model object(s) to test. A test need not begin from the Start-type element to start a Request. Therefore, mock Request data is necessary only from the Process model object from which to begin the test.

The following table describes the advantages and disadvantage to this method.

Specify the specific JSON data model to test in one of the following ways:

  • Create a Scenario, and then enter the specific JSON data model in the Data setting.

  • Run the test:

    1. Run the test from Process Modeler. It is not necessary to select a Scenario.

    2. Enter the specific JSON data model in the Additional Data setting.

Create the Scenario from a Request's Data

A method by which to create a Scenario is from a Request's data. This method does not require to know JSON, the data structure for the data model from which to test, or to build the data.

The following table describes the advantages and disadvantages to this method.

Follow these steps to create a Scenario from a Request data:

  1. Locate a Request summary or Task summary to verify that it contains the JSON data from which to create the Scenario.

  2. Evaluate the following about the Request's data under consideration:

    • The Request's workflow has proceeded to contain relevant data for the Process Test.

    • The values in that Request's data are those that you want for your Process Test. If not, then editing that Request's data may be necessary after creating the Scenario.

  3. Click the Create Scenario button from that Request or Task summary. The Create Scenario screen displays from which to create the Scenario.

Create a Scenario for a Process

Permissions Required

Your user account or group membership must have the following permissions to create Scenarios for a Process unless your user account has the Make this user a Super Admin setting selected:

  • Processes: Edit Processes

  • Processes: View Processes

See the Processes permissions or ask your Administrator for assistance.

Follow these steps to create a Scenario for a Process:

  1. Configure general settings for the Process. The Configuration tab displays.

  2. Click the Scenarios tab. Testing Scenarios display.

  3. Click the +Scenario button. The Create Scenario window displays.

  4. From the Name setting, enter the Scenario name for the Process. This is a required setting.

  5. From the Description setting, enter the Scenario description for the Process.

  6. From the Data setting, enter the JSON data model for the Process Scenario that mocks the Request data during Process Testing.

  7. Click Save.

© Copyright 2000-2024 ProcessMaker Inc. All rights reserved.