|
After recording a business case, if your test procedure requires dynamic substitution of URL parameters (POST or GET data) from cookies, response body, or from an external source such as database or CSV, Web Performance Test Studio provides the View or Parameterize URL option.
The advantages of using parameterization in the script is as follows:
Ability to achieve true real-world emulation while running the load test.
Dynamic Cookie and Session management.
Identify the category under which each of the URL parameters fall such as
Constant type parameters do not change values between a recorded session and a replay session. The values recorded can be used as it is for replay.
Dynamic parameters requires that their values be obtained from the response of the previous request. The parameter value can be extracted from one of the following:
|
Parameter Value Extracted From |
Description |
|---|---|
|
Cookie |
Fetch parameter value from the Cookie Set in the response header. |
|
Element |
Fetch parameter value from an element attribute value of a hidden form
|
|
Text (Response Body) |
Fetch parameter value from the body of the response.
Regular Expression:
[\s\S\n\r]*?sessionid=
<HTML> <TR><TD>Server Configuration </TD> <TD><A HREF=serverconfig.html?sessionid = 810> Config </A> </HTML> |
|
Javascript |
Fetch cookie or parameter value from the specified Javascript. |
|
URL |
Fetch cookie or parameter value from the previous URL for the given prefix and suffix text.
|
Parameters that need unique data for each use (such as user login and passwords) and that are fetched from any external datasource such as Database or FLAT file fall in this category.
For example, when testing a Web application that contains a login page, "parameterization” lets you use a different login name and password for each virtual user (dynamic substitution of values). There’s no need for each User Scenario to contain a separate script that performs the task of logging in.
Data parameterization for URL parameters is configured using the Configure Parameterization UI invoked using the Record->View or Parameterize URL menu item. To know the detailed steps of configuring the same, please refer to the context sensitive help in the following link.
|