Académique Documents
Professionnel Documents
Culture Documents
In HP LoadRunner
Advantages:
It reduces the size of the script.
It provides the ability to test your script with different values. For
example, if you want to search a library’s database for several titles,
you only need to write the submit function once. Instead of instructing
your Vuser to search for a specific item, use a parameter. During
replay, VuGen substitutes different values for the parameter.
To accomplish this, you will parameterize the script. This means that
you take the recorded value, Aisle, and replace it with a parameter. You
will place values for the parameter in a parameter file. When you run
the script, the Vuser will take values from the parameter file (aisle,
window, or none) thereby emulating a true travel agency environment.
After selecting a source of data, set the assignment properties for file.
These properties instruct VuGen how to use the data.
For example, they indicate which columns to use, how often to use new
values, and what do to when there are no more unique values.
The column number is the index of the column containing your data.
For example, if the data for the parameter is in the table’s first column,
select 1.
In the Column delimiter box of the File format section, enter the column
delimiter—the character used to separate the columns in the table. You
can specify a comma, tab, or space.
In the First data line box of the File format section, select the first line of
data to be used during Vuser script execution. The header is line 0. To
begin with the first line after the header, specify 1. If there is no header,
specify 0.
Random
Unique
Random
The Random method assigns a random value from the data table to
each Vuser at the start of the test run.
Unique
The Unique method assigns a unique sequential value to the parameter
for each Vuser. In this case you must make sure there is enough data
in the table for all the Vusers and their iterations. If you have 20 Vusers
and you want to perform 5 iterations, your table must contain at least
100 unique values.
>>>>>>>>>>>>>>>>>>>>>> www.softwaretestinggenius.com <<<<<<<<<<<<<<<<<<<<<<
Data Update Methods
Sequential Method
If you specify update on Each iteration, all the Vusers use Kim in the
first iteration, David in the second iteration, Michael in the third iteration,
and so on.
If you specify update on Each occurrence, all the Vusers use Kim in the
first occurrence, David in the second occurrence, Michael in the third
occurrence, and so on.
If you specify update Once, all Vusers take Kim for all iterations.
Important: If you select the Sequential method and there are not enough
values in the data table, VuGen returns to the first value in the table,
continuing in a loop until the end of the test.
>>>>>>>>>>>>>>>>>>>>>> www.softwaretestinggenius.com <<<<<<<<<<<<<<<<<<<<<<
Data Update Methods
Examples
Assume that your table/file has the following values:
Aman; Arun; Priya; Anjana; Sanjana; Rajan; Tarsem; Shiva; Madhur
Sequential Method
If you specify update on Each iteration, all the Vusers use Aman in the
first iteration, Arun in the second iteration, Priya in the third iteration,
and so on.
If you specify update on Each occurrence, all the Vusers use Aman in
the first occurrence, Arun in the second occurrence, Priya in the third
occurrence, and so on.
Random Method
If you specify update on Each iteration, the Vusers use random values
from the table for each iteration.
If you specify update Once, all Vusers take the first randomly assigned
value for all the iterations.
Unique Method
If you specify update on Each iteration, for a test run of 3 iterations, the
first Vuser takes Kim in the first iteration, Arun in the second, and Priya
in the third. The second Vuser takes Anjana, Sanjana and Rajan. The
third Vuser, Tarsem, Shiva, and Madhur.
If you specify update Once, the first Vuser takes Aman for all iterations,
the second Vuser takes Arun for all iterations, and so on.
Group Name
Iteration Number
Random Number
Unique Number
Vuser ID
Click Close to accept the settings and close the Parameter Properties
dialog box.