Defining Tests
All XLSior tests are defined on special worksheets called test sheets. Any sheet in your workbook whose name begins with X~Test is assumed to be a test sheet, unless it is called X~TestResults in which case it holds the results of running the tests.
A single test sheet can contain any number of tests. Each test is in a test set and contains a set of test data and a set of test conditions. All test sets must start in column A of the test sheet.
Test sheets
Any sheet in your workbook whose name begins with X~Test is assumed to be a test sheet, unless it is called X~TestResults in which case it holds the results of running the tests.
You can add a new test sheet to your workbook by using the command XLSior > Test > Add Test Sheet. You cannot add a new test sheet to a shared workbook.
The new sheet will be added before the currently active sheet, and will be called something like X~Test1, depending on the sheets that are already present in the workbook. You can rename the sheet to anything you like as long as the new name starts with X~Test (and isn't X~TestResults). The list of sheets on sheet X~Sheets will be updated each time you add a test sheet.
In small workbooks, one test sheet might be enough. In larger workbooks with many tests you will probably want to group the tests on separate sheets, to make them easier to manage. In this case it helps if you give the sheets names that reflect the purpose of the tests they define.
When XLSior looks for test definitions, it examines the contents of column A of each test sheet.
First, it expects cell A1 to contain some text. This text is used by the Autodocumentation facility, and should be a description of the sheet.
Next, it finds the beginning of a test set by looking for the text Test: in a cell in column A. The test data and test conditions are indicated by cells in column A containing Data: and Conditions: respectively.
Test sets
When you add a new test sheet, it will contain a single test set. The start of the test set is indicated by the text Test: in a cell in column A.
You can add a new test set to a test sheet by using the command XLSior > Test > Add Test Set.
The position of the new set on the worksheet will depend on where the currently active cell is. It will start in column A of the same row. Before the new test set is added, you will be shown its position and asked whether to go ahead with adding it. Note that adding a new test set may overwrite the existing contents of cells.
You should enter a description of every test set, briefly stating its purpose. You can add more detailed comments in the data and conditions section, but the description at the top of the test set is used to describe the test on the results sheet. The description can be as long as you like, but it is most helpful when it is fairly brief; say ten to twenty words.
Every test set should contain a data section and a conditions section. Each section starts with the relevant entry in column A (Data or Conditions) and ends when a further non blank cell is found in column A.
Test data
When you add a new test set, it will contain a single (empty) row of test data. You can add more rows by inserting rows in the spreadsheet, or moving the later rows down, in the usual way. XLSior does not use range names to define its tests.
The start of the data section is indicated by a cell containing the text Data: in column A.
Note that column A should be blank throughout the data section. The test definitions will not be read successfully unless all the cells are empty (except the first one, containing Data:).
Each row of test data defines a substitution that should take place when the test is run. You must specify a range whose values are to be replaced, and the values that are to be substituted.
The entries that you should make in each row of test data are:
- Comment
- Range
- Value type
- Substitute from
When you add new rows to a data set, you needn't worry about formatting them. XLSior will format them correctly the first time that it reads them. It will also add further entries in the row as described below.
If the XLSior system encounters any problems when reading the test data it will record them in the Notes entry of the relevant row.
Comment
You should enter a description of what this substitution is intended to accomplish. This helps you to design your tests effectively, and to work out the causes of failures.
Range
The Range entry is where you specify which cells should have their values replaced. There are two ways of doing this.
First, you can enter a formula in the cell. You can do this in the usual way, by typing an equals sign and then using the mouse to select the range. The advantage of using this method is that the range will be updated if it is moved or enlarged. The disadvantage is that, if it contains more than one cell, the entry will appear as #Value.
Second, you can type the range specification into the cell as text. For example, you could enter Sheet1!B6:B8. The advantage of using this method is that the entry is readily readable, and the disadvantage is that it will not be automatically updated.
Whichever method you use, you can use range names as well as absolute or relative addresses.
When the test definition has been read, a text version of the range definition will be placed in the Data range column to the right. This lessens the disadvantage of the first method.
There are some limitations on the types of ranges that can be specified:
- The range must be in the same workbook as the test definitions (no links to other workbooks)
- The range must consist of a single area, containing at least one cell
- The range cannot contain an array formula, or overlap with any range containing an array formula.
Value type
The Value type entry is where you specify how the substitution values are to be found. It can take one of two values: Direct or Range.
If the value type is Direct then the actual value in the Substitute from entry will be used. If it is Range then the Substitute from entry should specify a range whose values will be used.
Substitute from
The Substitute from entry is where you specify the substitution values.
If the Value type is Direct then the actual value from this cell will be used. The cell may contain either a value or a formula. If the Range contains more than one cell, the value will be substituted over the whole range.
If the Value type is Range then this cell should specify a range in the same way as the Range entry. The range that is specified should be the same size and shape as the range into which the values are to be substituted.
When the test definition has been read, a text version of the value definition will be placed in the Value column to the right.
Test conditions
When you add a new test set, it will contain a single (empty) row of test conditions. You can add more rows by inserting rows in the spreadsheet, or moving the later rows down, in the usual way. XLSior does not use range names to define its tests.
The start of the conditions section is indicated by a cell containing the text Conditions: in column A.
Note that column A should be blank throughout the conditions section. The test definitions will not be read successfully unless all the cells are empty (except the first one, containing Conditions:).
Each row in the conditions section defines a condition that must be true for the test to be passed. You must specify two values together with a method of comparing them.
The entries that you should make in each test condition are:
- Comment
- Value1
- Operator
- Value2
When you add new conditions, you needn't worry about formatting them. XLSior will format them correctly the first time that it reads them. It will also add further entries in the row as described below.
If XLSior encounters any problems when reading the test conditions it will record them in the Outcome entry of the relevant row.
After the conditions have been read a text representation of the condition will appear in the Condition column to the right of the row.
Comment
You should enter a description of what this condition is intended to accomplish. This helps you to design your tests effectively, and to work out the causes of failures.
Value1
This cell should contain a formula whose value is to be tested. After the tests have been run, the actual value that was used in the test will be entered in the Result of Value1 column to the right (ie, the value after the substitutions defined in the test data).
Operator
This cell should contain the operator (as a text entry) that should be used to compare Value1 and Value2. The valid operators are: = < > <> <= >= .
Value2
This cell should contain a formula whose value is to be tested. After the tests have been run, the actual value that was used in the test will be entered in the Result of Value2 column to the right (ie, the value after the substitutions defined in the test data).

