You can use the Datapool Literal Substitution dialog box to find
or replace literal values in a test script with a datapool reference (an associated
datapool). You can set the options in this dialog box to find and replace
all, number, string, or boolean literals in a script with a datapool reference.
You can also add a literal from a script to a datapool. If you
do not use an existing datapool variable, Functional Tester uses the same
literal values (the values that Functional Tester captured when you recorded
the test script) each time you run the script.
- Literal
- Displays the name of a selected literal in a script.
- Datapool Variable
- Type the name of the datapool variable with which you want to replace
a literal or click the Datapool Variable arrow to
select the existing datapool variable that you want the script to reference.
The default type for a new datapool column is string. You can change
the variable type later.
- Direction
- Select the direction that you want to move through a script. This setting
works with theLiteral Type setting. Click Find
or Replace to move either forward or backward through
a script starting from the insertion point of your cursor.
- Forward
- Click to move forward to the next literal in the script from the insertion
point.
- Backward
- Click to move backward to the next literal in the script from the insertion
point.
- Literal Type
- Click to set the type of literal that you want to find; either all, number,
string, or boolean literals in a script. A literal is a letter or symbol that
stands for itself as opposed to a feature, function, or entity associated
with the literal in a programming language: $ can be a symbol that refers
to the end of a line, but as a literal, it is a dollar sign. The Literal
Type setting works with the Direction
setting. Click Find or Replace
to move to the next type of literal through a script starting from the insertion
point of your cursor.
- All
- Click to find all literals in a script.
- Numbers
- Click to find number literals in a script. A number includes integers
(a whole number, not a fractional number, that can be positive, negative,
or zero) or floating numbers (positive and negative decimal numbers).
- Strings
- Click to find string literals in a script. A string stores alphanumeric
values such as name, city, or state.
- Booleans
- Click to find boolean literals in a script. Any use of the boolean literals
true or false are flagged for substitution.
- Add Literal to Datapool
- Click to add a selected literal to a datapool variable when you click Replace.
The selected literal is added to the datapool in the variable that you specify
in Datapool Variable. A datapool reference replaces
the selected literal when you click Replace.
- Find
- Click to find the next literal in a script. The Find setting
works with the Direction and Literal Type settings.
- Replace
- Click to replace the selected literal with a datapool reference. The datapool
reference is made to the datapool variable you specify in Datapool Variable.
When you click Add literal to datapool, Functional
Tester adds a selected literal to the datapool variable you specify in Datapool Variable.
Automatically moves to the next literal in the test script after replacing
a literal. The Replace setting works with the Direction and
Literal Type settings.
- Close
- Click to close the dialog box without finding a literal or replacing a
literal with a datapool reference.
To open: Click Script > Find Literals and Replace
with Datapool Reference.