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.
Advantage | Disadvantage |
---|---|
Do not need a Scenario to run a test | Requires to know JSON to either build the JSON data model or copy from Request data |
Need only the specific mock Request data from which to test |
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:
Run the test from Process Modeler. It is not necessary to select a Scenario.
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.
Advantage | Disadvantage |
---|---|
Does not require knowing JSON | Requires running real Requests from which to create the Scenario, thereby triggering logging events and data available to Saved Searches |
No need to build the JSON data model | Scenario contains the JSON data model only to the last triggered object in that Request, which may not contain |
Scenario may not contain exactly the mock Request data to test, so editing the Scenario may be required |
Follow these steps to create a Scenario from a Request data:
Locate a Request summary or Task summary to verify that it contains the JSON data from which to create the Scenario.
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.
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
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:
Configure general settings for the Process. The Configuration tab displays.
Click the Test Run/Scenarios tab. Testing scenarios display.
Click the +Scenario button to create a new scenario.
From the Name setting, enter the Scenario name for the Process. This is a required setting.
From the Description setting, enter the Scenario description for the Process.
From the Scenario Creation Type setting, do one of the following:
Select Manual Data to enter JSON data for the scenario. Then, from the Data setting, enter the JSON data model for the Process Scenario that mocks the Request data during Process Testing.
Select Document Upload to create multiple scenarios simultaneously. This option requires a pre-formatted
.xlsx
file. Click the Download Format button to download a sample file, then edit it to include your scenarios. Then, click the Upload button to upload the scenario file.
Click Save to save the scenarios.
Search for a Scenario in a Process
Permissions
Your user account or group membership must have the following permissions to search for 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 search Scenarios for a Process:
Configure general settings for the Process. The Configuration tab displays.
Click the Scenarios tab. Testing scenarios display.
Enter in the Search setting the text to filter Scenarios.
As you enter text into the Search setting, Scenarios display that match your entered text.
If there are no search results, the following message displays: No Results.
Edit a Scenario for a Process
Permissions
Your user account or group membership must have the following permissions to edit 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 edit a Scenario for a Process:
Configure general settings for the Process. The Configuration tab displays.
Click the Scenarios tab. Testing scenarios display.
Click the three dots icon, and then select the Edit Scenario option for the Scenario to edit. The Edit Scenario window displays.
Edit the following if necessary:
From the Name setting, edit the scenario name for the Process. This is a required setting.
From the Description setting, edit the Scenario description for the Process.
From the Data setting, edit the JSON data model for the Process Scenario that mocks the Request data during Process Testing.
Click Save.
Delete Scenarios in a Process
Permissions
Your user account or group membership must have the following permissions to delete Scenarios for a Process unless your user account has the Make this user a Super Admin setting selected:
Processes: Delete Processes
Processes: View Processes
See the Processes permissions or ask your Administrator for assistance.
Follow these steps to delete a Scenario for a Process:
Configure general settings for the Process. The Configuration tab displays.
Click the Scenarios tab. Testing Scenarios display.
Click the three dots icon, and then select the Delete option for the Scenario. The Caution window displays to confirm the deletion of the Scenario.
Click Confirm.