Testing modules allows to test parts or the whole algorithm design in Higson Studio. Using batch tester gives the ability to perform test for series of data, not just a singular set. Create and save mass tests to control how changes it the algorithm influence the results. Each batch test is created from unit test (design in singular tester). To learn more about the Unit tests read the Tester chapter.
To go to batch tester, select Tools/Batch Tester in Main Toolbar.
You will see all saved batch tests
Each batch test is listed in the center of the screen, every single one is described by four information’s:
| No. | Column name | Description |
|---|---|---|
| 1. | Test Name | Batch test name. Each batch test should have unique name. |
| 2. | User | Login of the user who created the batch test. |
| 3. | Last Modified | Date of the last modification of the batch test. |
| 4. | Actions | List of quick access actions. Currently only Remove action (bin icon) is available here.Remove action deletes desired batch test. |
Additionally you can use available actions:
| No. | Action | Description |
|---|---|---|
| 1. | + Add test package | Opens a batch test creator. |
| 2. | Upload test package | Allows to upload batch test from XLSx file |
| 3. | Hide/Show filters | Hides or reveals Filters bar accordingly. If Filter bar: - is visible, then action Hide filters is available. - is hidden, then action Show filters is available. |
Use filters to search for preferred batch test:
| No. | Filter name | Description |
|---|---|---|
| 1. | Search text field | Filter by any string provided by user. |
| 2. | Date range | Filter by last change date in format YYYY/MM/DD-YYYY/MM/DD . |
| 3. | Modified by | Filter by user who last modified the batch test. |
Batch tester creator#
To create new batch test unit test must already exist. You can create unit test using the Tester. When this condition is met you can start creating batch tests based on existing unit tests.
The Batch Test creator:
For each unit test, which creates batch test, six information is given:
| No. | Column name | Description |
|---|---|---|
| 1. | Test Name | Full test name. Test name is loaded from selected unit test. Test name can be changed (or added) through import of the XLSx file. |
| 2. | Status | Test case status provided by comparison of the evaluated value with expected value. |
| 3. | Failures | Number of failures within unit test case. Where evaluated value differs from expected value. |
| 4. | Errors | Number of errors which occurred during the unit test. |
| 5. | Time (ms) | Time taken to perform the unit test. |
| 6. | Actions | List of quick access actions. Currently only Remove action (bin icon) is available here. Remove action deletes desired unit test. |
By those the list of unit test can be sorted if needed.
| No. | Action | Description |
|---|---|---|
| 1. | Checkboxes | Select the top checkbox to select all unit tests in the view, or select individual checkboxes to select unit tests |
| 2. | + Add test | Opens a batch test creator. |
| 3. | Upload package | Allows to upload batch test from XLSx file |
| 4. | Download package | Allows to download batch test from XLSx file |
| 5. | Remove selected tests | Deletes all unit test with marked checkboxes. Available only if at least: one unit test was added, and one checkbox is selected |
| 6. | Save package | Saves batch test for further use. |
| 7. | Run test | Runs batch test, performs all unit test cases added to viewed batch test. Every batch test can be run (even not saved) |
Batch tester - creating a batch test#
To create new batch test, follow these steps:
-
Go to Main Toolbar
a. Select Tools
b. in Tools select Batch Tester
-
Click “Add test package”
-
Your first action should be filling the Name for the Batch Test. Name can contain only characters from collection a-z; A-Z; 0-9; “-”; “_”.
-
Next click +Add test
a. Select unit test you wish to base the batch test on
b. If test loaded correctly to batch tester it will show on the list of the unit tests
-
Click on Run test to get the results
-
Now, when the template has been provided you can Download the batch test to your computer as XLSx file. Click on Download package
-
Open the XLSx file
a. The template should look similar to this
b. add data series according to your needs
c. save the edited file
-
Upload the batch test:
a. Click on Upload package
b. Load the updated file from your computer
c. Click Upload
-
When the file is loaded correctly and you will click Run test again the result of all loaded test cases should show
-
Lastly, to be able to get back to created batch test case you must save it by clicking : Save package:
a. add the name for the batch test, if you have not added it yet. For Batch test name allowed characters are a-z, A-Z and symbols: -_
b. click on Save package
Batch tester - Upload a batch test#
You can upload test package in two ways. First from the Batch Tester Panel:
-
Click on Upload test package:
-
Load the file from your computer
-
Click Upload button to accept the selected file for upload
-
The uploaded batch test should show on the list
The other way is to create new batch test:
-
In the Batch Tester Panel click on Add test package (in actions panel)
-
On batch test creator view, in action panel click on Upload package
-
Select the XLSx file with the definition of the batch test
a. Load file
b. Click upload
-
After successful download remember to save the batch test
Batch tester - Download a batch test#
When working on selected batch test:
-
Click on Download package
-
The XLSx file will be generated with definition of the batch test, save the file.
Batch tester - Reading & Editing the XLSx file#
Each XLSx from batch test is created according to the rules:
- There are always three sections with data
- Each sections may have multiple columns
- Data sections are separated by empty column, with header
#or##
First sections:
- starts with column including test case name
- each next column contains one input value
Second section:
- for each tested element one column is created
- each column contains result expected value for one of the tested elements
Third section:
- for each tested element two columns are created
- first column contains evaluated value for the tested element
- second column contains value of the difference between calculated result and expected result
First section:#
Column headers are indicators of what kind of variable is needed. Usually in the context header is a context path which is used in tested elements.
Second section:#
In each header two informations are stored:
-
Type of element in the test case
- att@ for domain business attribiute
- par@ for decision table
- fun@ for function
-
Code of that element
- in case of attr@ after element type domain path is given
- in case of par@ or fun@ after element type element code is given
Third section:#
In each header three informations are stored:
- Value Type :
- Evaluated - for columns holding values evaluated by the algorithm
- Diff - for the value of the difference between what was calculated and what was expected
- Type of element in the test case
- att@ for domain business attribute
- par@ for decision table
- fun@ for function
- Code of that element
- in case of attr@ after element type domain path is given
- in case of par@ or fun@ after element type element code is given
Run Batch Test#
To Run an existing batch test follow these steps:
-
Go to Main Toolbar
a. Select Tools
b. in Tools select Batch Tester
-
You will see Batch Tester Panel, filled with all existing batch tests
-
Click on selected batch test, to view it’s details
-
Batch test view, in our example:
-
When you click on selected test
-
Here you are able to view test details and if needed change:
a. Input values
b. Expected values
c. Or even change tested elements in selected unit test case (full description on how to create and edit Unit Test Cases can be found in the User Guide Tester chapter)
-
When all the changes are made
a. If you want to save this Unit test and be able to view it in singular Tester just click Save test
b. It’s not obligatory to Save test as you would in Unit Tester. Just get back to the batch test by clicking the Package button
-
On the batch test view click Run package to perform your tests
-
For each unit test a result status will show:
All possible statuses are described here:
No. Status Description 1. Success When unit test performs without problems and result value is equal to expected value. 2. Failure Can occur in two situations:
- The result value is not equal to expected value
- The Error occur during performing the unit test -
Beside Status there are other information given by batch tester
| No. | Column name | Description |
|---|---|---|
| 1. | Status | Test case status (Success/Failure) depending on whether test was performed with positive result |
| 2. | Failures | Number of failures within unit test case. Where evaluated value differs from expected value. |
| 3. | Errors | Number of errors which occurred during the unit test. |
| 4. | Time (ms) | Time taken to perform the unit test. |