Steve-3PO
7 years agoNew Contributor
Using an Excel DataSource with DataSourceLoop - Changing employee ID on each loop
I am trying to load large amounts of data from an excel sheet using the DataSource tool, calling a REST API and then looping it with the DataSoureLoop until all rows in the excel sheet have sent via...
- 7 years ago
Thank you for posting to our Community Forum.
You can nest DataSource loops so that for each employee you run through every possible shift. Here is how that could be structured.
1. Employee DataSource - contains all employee ids
2. Shifts DataSource - contains all possible shifts
3. API Call/ other needed TestSteps
4. DataSource Loop to iterate the Shifts Data Source
5. DataSource Loop to iterate the Employees DataSource.
Attached you can find the example TestCase XML File that I used to illustrate the structure. Note that I used a script to log the ids and shifts to show the concept since I don't have an API call to make.
Have a great day!