Monday, March 24, 2008

Winrunner questions from Interviewer point of view

Screening questions: Interviewer can Reject the candidate if he /she is not able to answer 2 questions out of following 4 questions:
1. Where did you learn WinRunner and TestDirector?
If they say it was in a mercury class, ask if they can show you theircertificate of completion. If they say no, let them know you will verify itwith Mercury.
2. Have you ever created a start-up script?
If they answer “yes”, ask themwhat was in it and how they got WR to execute the start-up script when WR isinvoked.
They should answer something like this, “In the start-up script, we loaded allthe gui maps for the application, any library files we needed, and any customgui object mapping we have to do. We also loaded global variables and systemvariables here. The startup script location is added to the WR .ini file,wrun.ini located under the windows or winnt directory as wrun.ini”
3. What is the difference between writing a function and writing a script?
They should mention some of these things:1. A function goes into a “compiled module”, a script does not.2. A function follows strict “c” syntax. For instance, you have to declareall variables created and used in the function. In a script you do not.
4. What is the difference between “set_window” and “win_activate”.?When would you use “set_window” and when would you use “win_activate”?win_activate has the format win_activate(window);. The win_activate functionmakes the specified window the active window by bringing it into focus andraising it to the top of the display. (It is the equivalent to clicking on thewindow banner)
Set_window has the following format: set_window(window,[time]);The set_window function directs input to the correct application window. Thisdirects the GUI map to this window. It also sets the scope for objectidentification in the GUI map.
The most important difference is that set_window has a timing option.WinRunner will wait a maximum of the number used in the function, PLUS thesystem set timeout, to wait for the window to appear. Win_activate assumes thewindow is already on the desktop and has no timing option.

No comments: