Interview Questions

WinRunner: How to Structure tests for Web:

Mercury WinRunner FAQ


(Continued from previous question...)

WinRunner: How to Structure tests for Web:

Create Begin and End Scripts. This will ensure that WinRunner starts and stops from the same place.
. Mercury recommends that it is better to use smaller specific GUI maps for your testing than have one large GUI map that encompasses your whole application.
. Comment all major selections or events in the script. This will make debugging easier
. Need to create a init script to load correct GUI map, font group and set option variables.
A few of the options you should set are:
# Turns off real time error message reporting if the test case
# fails. The error is still logged in the test results window.
setvar ("mismatch_break", "off");
# Turn off beeping
setvar ("beep", "off");
setvar ("sync_fail_beep", "off");
# Make sure context sensitive errors don't trigger real time
# failures that stop the script. The error is still logged in the
# test results window.
setvar ("cs_fail", "off");
# Sets time winrunner waits between executing statements
# (Mercury default is 0)
setvar ("cs_run_delay", "500");
# Sets time winrunner waits to make sure window is stable
# (Mercury default is 1000)
setvar ("delay_msec", "500");
# Sets the fail test when single property fails to uncheck (bug - recommend set to un-check) setvar ("single_prop_check_fail", "0");
. Determine all paths to start up directory and then set them in the options window.
. In your closing/ending scripts use the GUI_unload_all command to unload all GUI maps in memory.

(Continued on next question...)

Other Interview Questions