Wednesday, July 3, 2013

LR Web Vuser Functions: C language


Web Vuser Functions:




Action Functions

"web_custom_request"   To create a custom HTTP request with any method supported by HTTP.
"web_image"       Emulates a mouse click on the image defined by the attributes.
"web_link"       Emulates a mouse click on the link defined by the attributes.
"web_submit_data"       Performs an "unconditional" or "contextless" form submission.
"web_submit_form"       Emulates the submission of a form.
"web_url"               Loads a specific URL.


Authentication Functions

"web_set_certificate" To use a specific certificate that is listed in the Internet Explorer registry.
"web_set_certificate_ex" Specifies location and format information of a certificate and key file.
"web_set_user" Specifies a login string for a Web server.


Asynchonous Functions

"web_stop_async"         Stops the specified Asynchronous Conversation including all its active and                future tasks.
"web_util_set_request_body" Sets the specified string to be the request body for the next request sent in the Conversation.
"web_util_set_request_url" Sets the specified string to be the request URL for the next request sent in the Conversation.
"web_reg_async_attributes" Registers the next action function that has requests and responses with the specified URL as the beginning of an Asynchronous Conversation.
"web_reg_cross_step_download" Registers a request to allow the download of the specified URL to continue beyond the step that initiated it.
"web_sync"          Suspends the Vuser script execution until the specified parameter exists.

Callbacks

"Request Callback"                         Called before a request is sent.
"Response Body Buffer Callback" Called when there is content in the response body buffer and at the end of the response body.

"Response Callback"                         Called once at the end of a conversation


Check Functions

"web_find"                 Searches inside an HTML page for a specified text string.
"web_global_verification"                 Searches for text string in all subsequent requests.
"web_global_verification_pause" Suspends the specified checks set by web_global_verification.
"web_global_verification_resume" Resumes the specified checks suspended by web_global_pause.
"web_image_check"                 Verifies the presence of a specified image inside an HTML page.
"web_reg_find"                 Registers a search for a text string for the next Action function.


Connection Definition Functions

"web_enable_keep_alive"            Enables keep alive HTTP connections.
"web_disable_keep_alive"            Disables Keep-Alive HTTP connections.


Concurrent Group Functions

"web_concurrent_end" Marks the end of a concurrent group.
"web_concurrent_start" Marks the beginning of a concurrent group.

The following functions can be used within a concurrent group:

"web_url"
"web_submit_data"
"web_custom_request"
"web_create_html_param"
"web_create_html_param_ex"
"web_reg_save_param"
"web_add_header"


Cookie Functions

"web_add_cookie"         Adds a new cookie or modifies an existing one.
"web_add_cookie_ex" Adds a cookie with specified add behavior.
"web_cleanup_cookies" Removes all cookies currently stored by the Vuser.
"web_reg_add_cookie" Registers a search for a text string and adds a cookie if the text is found.
"web_remove_cookie" Removes the specified cookie.


Correlation Functions*

"web_create_html_param" Saves dynamic information on an HTML page to a parameter. (Obsolete: use only for LR 6.5 and below)
"web_create_html_param_ex" Saves recurring dynamic information on an HTML page to a parameter. (Obsolete: use only for LR 6.5 and below)
"web_reg_save_param"   Deprecated: Use "web_reg_save_param_ex", "web_reg_save_param_regexp" or "web_reg_save_param_xpath".       Saves non-NULL terminated dynamic data from an HTML page to a parameter.
"web_reg_save_param_ex"        Registers a request to save dynamic data located between specified boundaries to a parameter.
"web_save_param_length"         Saves the length of a parameter
"web_reg_save_param_regexp" Registers a request to save dynamic data that matches a regular expression to a parameter.
"web_reg_save_param_xpath" Registers a request to find dynamic data in an HTML buffer that has been formatted as XML and save the data to a parameter.
"web_save_timestamp_param" Saves the current timestamp.
"web_set_max_html_param_len" Sets the maximum length of retrieved dynamic HTML information.


Data Format Functions

"web_convert_from_formatted"   Converts a string created with one or more data format extensions back to the source format.
"web_convert_param" Converts an HTML parameter to a URL or text.
"web_convert_to_formatted" Formats data using one or more data format extensions.


Filter Functions

"web_add_filter"           Sets criteria to include or exclude URLs when downloading (applies to the next action function only).
"web_add_auto_filter"  Sets criteria to include or exclude URLs when downloading (applies to all subsequent action functions).
"web_remove_auto_filter"   Removes a filter on download content.


Header Functions

"web_add_auto_header"   Adds a customized header to all subsequent HTTP requests.
"web_add_header"         Adds a customized header to the next HTTP request.
"web_cleanup_auto_headers" Stops adding customized headers to subsequent HTTP requests.
"web_remove_auto_header" Stops adding a specific header to subsequent HTTP requests.
"web_revert_auto_header" Stops adding a specific header to subsequent HTTP requests, but generates Implicit headers.
"web_save_header"        


Proxy Server Functions

"web_set_pac"         Sets the location of the proxy auto-configuration (PAC) script.
"web_set_proxy" Specifies that all secure HTTP requests be directed to the specified proxy server.
"web_set_proxy_bypass" Specifies the list of URLs that scripts access directly, i.e., not via the specified proxy server.
"web_set_proxy_bypass_local"   Specifies whether or not the proxy server should bypass local addresses.
"web_set_secure_proxy" Specifies that all secure HTTP requests be directed to the specified secure proxy server.


Replay Functions

"web_set_max_retries" Sets the maximum number of retries for an Action step.
"web_set_option"         Sets a Web option.
"web_set_timeout"         Specifies the maximum amount of time that a script waits for a specified operation to be performed.


Service Functions

Service functions perform a task, manipulate, or analyze the data that was received from the server. Many of the tasks done by the service functions can be set by using the Run-Time settings. Advanced users can use the service functions to change settings from inside a script.

Service functions are preceded by the word Service in the treeview representation of the script. For example, Service: Add Auto Header.Saves request and response headers to a variable.


Miscellaneous Functions

"web_cache_cleanup"           Clears the contents of the cache simulator.
"web_convert_date_param"        Converts a date string stored in a parameter to a different format.
"web_convert_param"           Converts an HTML parameter to a URL or text.
"web_dump_cache"                   Save the Vuser cache to a file.
"web_get_int_property"           Returns specific information about the previous HTTP request.
"web_js_reset"                   Resets the JavaScript engine context for the Vuser.
"web_js_run"                   Runs the specified JavaScript.
"web_load_cache"                   Load the Vuser cache from a file.
"web_reg_cross_step_download" Registers a request to allow the download of the specified URL to continue beyond the step that initiated it.
"web_report_data_point"           Specifies a data point and adds it to the test results.
"web_sjis_to_euc_param"           Converts an SJIS string to EUC and assigns it to a parameter.
"web_set_sockets_option"          Sets an option for secure sockets.
"web_switch_net_layer"           Specifies a network layer for replay. (WAP only)



Web (Click and Script) Vuser Functions


Web (Click and Script) functions are GUI Level Vuser Functions. They have a web_xxx prefix, like other HTTP-related functions. Web (Click and Script) Vuser Functions emulate user actions, like clicking on an element, selecting a radio button, and others. The GUI level functions are used together with other HTTP-related functions in the same scripts.


"web_browser"  Performs an action on a browser.
"web_button"         Emulates a user clicking on button.
"web_check_box" Selects or clears a check box.
"web_edit_field" Enters data for text and password input fields.
"web_element"         Emulates a user clicking on an element defined with any HTML tag.
"web_file"                 Enters a path for file input elements.
"web_image_link" Emulates a user clicking on an image that is a hypertext link.
"web_image_submit" Emulates a user clicking on an image that fires a submit request.
"web_list"                 Selects an item from a list control.
"web_map_area" Activates an area within a client side map.
"web_radio_group" Selects one button from a radio button group.
"web_reg_cross_step_download" Registers a request to allow the download of the specified URL to continue beyond the step that initiated it.
"web_reg_dialog" Registers user response for the subsequent call to a JavaScript function.
"web_static_image" Emulates a user clicking on a static image.
"web_table"         Emulates a user action on a table.
"web_text_area" Enters text in an input text area.
"web_text_link"  Emulates a user clicking on a hypertext link.


No comments:

Post a Comment