Forum Discussion
M_McDonald
13 years agoSuper Contributor
Create a DataGen step after the DataSource step and before the request step with 3 items:
1) A Template property for the first person with property expansions that refer to the DataSource (eg. <FirstName>${DataSource#firstname}</FirstName><LastName>...)
2) A Groovy property for the second with this code:
3) A Template property for the second person with property expansions identical to the first one.
Make sure the Mode for each item is STEP.
Then put property expansions for the 2 template properties in your request.
The Groovy script will cause the DataSource to be incremented so that each template will get data from a different row.
1) A Template property for the first person with property expansions that refer to the DataSource (eg. <FirstName>${DataSource#firstname}</FirstName><LastName>...)
2) A Groovy property for the second with this code:
testRunner.testCase.getTestStepByName('DataSource').next(testRunner, context)
3) A Template property for the second person with property expansions identical to the first one.
Make sure the Mode for each item is STEP.
Then put property expansions for the 2 template properties in your request.
The Groovy script will cause the DataSource to be incremented so that each template will get data from a different row.
Related Content
- 6 years ago
- 4 years ago
- 4 years ago
Recent Discussions
- 2 days ago
- 3 days ago