Scenario tests can now apply dynamic data to text fields for real-time application of information in a UI recording.
- Record a scenario test using static data. See Creating scenario tests for more information.
- In the navigation page of Dev Studio click .
- Select the test case for which you want to edit.
- Navigate to the Setup & Cleanup tab of the test case.
- In the Setup section of this tab, you can create or fetch test data using one of the setup options available from the drop down menu. You can apply a data transform, execute an activity, or load an object. Scenario tests can fetch and use any of this setup information as dynamic input data.
- Input a name for the activity.
- On the setupDynamicData page, create the dynamic value and associate it to a
property for use in your scenario test case. For instance, on the
PersonPage in the example below, the
.pyLabel property consists of the
dynamic data structure.
- To utilize this dynamic field in your test case, navigate back to your scenario test case.
- From the Test case steps section, select the step that contains the text field.
- After selecting the test case step, navigate to the Actions field, and change the value type to Dynamic.
- In the Value field, enter the page.property value created as part of your
activity in Step 8. In this case, it is PersonPage.pyLabel.
- Click Save.