Read Data From Excel
This page describes how to configure Provar to test using data from Excel.
Add Parameter Value Source
In order to read from an Excel sheet, first ensure you have your Excel file ready in your local.
It is good practice to save the file in the Templates folder in your workspace.
This then needs to be accessed or imported into your Provar Test Case. You can do this at any Test Step by clicking on the ‘Add Parameter Value Source’ icon:
Configure Excel Source
Take the following steps to configure how Provar should read the Excel sheet.
- Highlight the range of cells you want to test with and select CTRL C to copy.
- Navigate to Provar and select the yellow arrow pointing to the left. This will populate the ‘File’, ‘Worksheet’ and the ‘Values Range’ fields.
- Select the orientation of the headers.
- Populate the WHERE clause if you want to filter the sheet.
- Specify the object name for the results (the default is ‘ExcelData’).
- Parameterize the Test Case.
Add to Test Case
Once you have read the Data from the excel sheet, you need to use it in your Test case. This is typically done using a For Each or While API, to loop through multiple rows, and a Create Test Step to create the data at the API level.
- Use the Variable picker to access the fields in the ‘ExcelData’ object.
- Specify the list Name (‘ExcelData’) and the Value Name in the For Each API. (The Value Name is the name for the current iteration.)
- Use the full stop to access the column headings: