TSL Scripts

TSL Scripts for Web Testing
1. web_browser_invoke (browser, site);
// invokes the browser and opens a specified site. browser The name of browser (IE or Netscape) site
2. web_cursor_to_image (image,x,y);
// moves the cursor to an image on a page. image The logical name of the image. x, y. The x- and y- coordinates of the mouse pointer when moved to an image
3. web_cursor_to_label (label, x,y);
// moves the cursor to a label on a page. label The name of the label. x, y The x- and y- coordinates of the mouse pointer when moved to a label.
4. web_cursor_to_link (link,x,y);
// moves the cursor to a link on a page. link The name of the link. x,y The x- and y- coordinates of the mouse pointer when moved to a link
5. web_cursor_to_obj (object, x,y);
// moves the cursor to an object on a page object The name of the object. x,y The x- and y- coordinates of the mouse pointer when moved to an object
6. web_event (object, event_name [x,y]);
// moves an event on a specified object. object The logical name of the recorded object. event_name The name of an event handler. x,y The x- and y- coordinates of the mouse pointer when moved to an object
7. web_file_browse (object);
// clicks a browser button. object A file-type object
8. web_file_set (object,value);
// sets the text value in a file-type object. object A file-type object. Value A text string
9. web_find_text (frame, text_to_find, result_array [,text_before, text_after, index, show]);
// returns the location of text within a frame
10. web_frame_get_text (frame,out_text [, text_before, text_after, index]);
// retrieves the text content of a frame 
11. web_frame_get_text_count (frame, regex_text_to_find, count);
// returns the number of occurrences of a regular expression in a frame
12. web_frame_text_exists (frame,text_to_find[, text_before, text_after]);
// returns a text value if it is found in a frame
13. web_get_run_event_mode (out_mode);
// returns the current run mode out_mode The run mode in use. If the mode is FALSE, the default parameter, the test runs by mouse operations. If TRUE, is specified, the test runs by events
14. web_get_timeout (out_timeout);
// returns the maximum time that winrunner waits for response from the web. out_timeout The maximum interval in seconds
15. web_image_click (image, x, y);
// clicks a hypergraphic link or an image. image The logical name of the image. x,y The x- and y- coordiantes of the mouse pointer when clicked on a hypergraphic link or an image
16. web_label_click (label);
// clicks the specified label. label The name of the label
17. web_link_click (link);
// clicks a hypertext link. link The name of link
18. web_link-valid (name, valid);
// checks whether a URL name of a link is valid (not broken). name The logical name of a link. valid The status of the link may be valid (TRUE) or invalid (FALSE)
19. web_obj_click (object, x, y);
// object The logical name of an object, x, y The x- and y- coordinates of the mouse pointer when clicked on an object
20. web_obj_get_child_item (object, table_row, table_column, object_type, index, out_object);
// returns the description of the children in an object
21. function returns the count of the children in an object
web_obj_get_child_item_count (object, table_row, table_column, object_type, object_count);
22. returns the value of an object property
web_obj_get_info (object, property_name, property_value);
23. returns a text string from an object
web_obj_get_text (object, table_row, table_column, out_text [, text_before, text_after, index]);
24. returns the number of occurance of a regular expression in an object
web_obj_get_text_count (object, table_row, table_column, regex_text_to_find, count);
25. returns a text value if it is found in an object
web_obj_text_exists (object, table_row, table_column, text_to_find [, text_before, text_after]);
26. web_restore_event_default ();
// resets all events to their default settings
27. web_set_event_name, event_type, event_status);
// sets the event status
28. web_set_run_event_mode (mode);
// sets the event run mode
29. web_set_timeout (timeout);
// sets the maximum time winrunner waits for a response from the web
30. web_set_tooltip_color (fg_color, bg_color);
// sets the colors of the web test tool tip
31. web_sync (timeout);
// waits for the navigation of a frame to be completed
32. we_url_valid (URL, valid);
// checks whether a URL is valid

No comments:

Post a Comment