Frequently Asked WinRunner Interview Questions
Q – 1 What is the extension of gui map file?
Ans- The extension for a GUI Map file is “.gui”.
Q – 2 What do you verify with the sync point for object/window bitmap and what command it generates, explain syntax?
Ans- You can create a bitmap synchronization point that waits for the bitmap of an object or a window to appear in the application being tested.
During a test run, WinRunner suspends test execution until the specified bitmap is redrawn, and then compares the current bitmap with the expected one captured earlier. If the bitmaps match, then WinRunner continues the test.
Syntax:
obj_wait_bitmap ( object, image, time );
win_wait_bitmap ( window, image, time );
Q – 3 What do you verify with the database check point custom and what command it generates, explain syntax?
Ans-
* When you create a custom check on a database, you create a standard database checkpoint in which you can specify which properties to check on a result set.
* You can create a custom check on a database in order to:
o check the contents of part or the entire result set
o edit the expected results of the contents of the result set
o count the rows in the result set
o count the columns in the result set
* You can create a custom check on a database using ODBC, Microsoft Query or Data Junction.
Q – 4 How do you handle dynamically changing area of the window in the bitmap checkpoints?
Ans- The difference between bitmaps option in the Run Tab of the general options defines the minimum number of pixels that constitute a bitmap mismatch
Q – 5 What information is contained in the checklist file and in which file expected results are stored?
Ans- The checklist file contains information about the objects and the properties of the object we are verifying.
The gui*.chk file contains the expected results which is stored in the exp folder
Q – 6 How do you view the contents of the GUI map?
Ans- GUI Map editor displays the content of a GUI Map. We can invoke GUI Map Editor from the Tools Menu in WinRunner. The GUI Map Editor displays the various GUI Map files created and the windows and objects learned in to them with their logical name and physical description.
Q – 7 What are the two modes of recording?
Ans- There are 2 modes of recording in WinRunner
1. Context Sensitive recording records the operations you perform on your application by identifying Graphical User Interface (GUI) objects.
2. Analog recording records keyboard input, mouse clicks, and the precise x- and y-coordinates traveled by the mouse pointer across the screen.
Q – 8 How do you find out which is the start up file in WinRunner?
Ans- The test script name in the Startup Test box in the Environment tab in the General Options dialog box is the start up file in WinRunner.
Q – 9 What is the purpose of different record methods
1) Record
2) Pass up
3) As Object
4) Ignore.?
Ans-
1) Record instructs WinRunner to record all operations performed on a GUI object. This is the default record method for all classes. (The only exception is the static class (static text), for which the default is Pass Up.)
2) Pass Up instructs WinRunner to record an operation performed on this class as an operation performed on the element containing the object. Usually this element is a window, and the operation is recorded as win_mouse_click.
3) As Object instructs WinRunner to record all operations performed on a GUI object as though its class were object class.
4) Ignore instructs WinRunner to disregard all operations performed on the class.
Q – 10 How do you analyze results and report the defects?
Ans- Following each test run, WinRunner displays the results in a report. The report details all the major events that occurred during the run, such as checkpoints, error messages, system messages, or user messages. If mismatches are detected at checkpoints.
Q – 11 How do you run your test scripts?
Ans- We run tests in Verify mode to test your application. Each time WinRunner encounters a checkpoint in the test script, it compares the current data of the application being tested to the expected data captured earlier. If any mismatches are found.
Q – 12 Have you performed debugging of the scripts?
Ans- Yes, I have performed debugging of scripts. We can debug the script by executing the script in the debug mode. We can also debug script using the Step, Step Into, Step out functionalities provided by the WinRunner.
Q – 13 What is a checkpoint and what are different types of checkpoints?
Ans- Checkpoints allow you to compare the current behavior of the application being tested to its behavior in an earlier version.
You can add four types of checkpoints to your test scripts:
1. GUI checkpoints verify information about GUI objects. For example, you can check that a button is enabled or see which item is selected in a list.
2. Bitmap checkpoints take a snapshot of a window or area of your application and compare this to an image captured in an earlier version.
3. Text checkpoints read text in GUI objects and in bitmaps and enable you to verify their contents.
4. Database checkpoints check the contents and the number of rows and columns of a result set, which is based on a query you create on your database.
Q – 14 What are data driven tests?
Ans- When you test your application, you may want to check how it performs the same operations with multiple sets of data. You can create a data-driven test with a loop that runs ten times: each time the loop runs, it is driven by a different set of data.
In order for WinRunner to use data to drive the test, you must link the data to the test script which it drives. This is called parameterizing your test. The data is stored in a data table. You can perform these operations manually, or you can use the DataDriver Wizard to parameterize your test and store the data in a data table.
Q – 15 What are the synchronization points?
Ans- Synchronization points enable you to solve anticipated timing problems between the test and your application. For example, if you create a test that opens a database application, you can add a synchronization point that causes the test to wait until the database records are loaded on the screen.
For Analog testing, you can also use a synchronization point to ensure that WinRunner repositions a window at a specific location. When you run a test, the mouse cursor travels along exact coordinates. Repositioning the window enables the mouse pointer to make contact with the correct elements in the window.
Q – 16 What is parameterizing?
Ans- In order for WinRunner to use data to drive the test, you must link the data to the test script which it drives. This is called parameterizing your test. The data is stored in a data table.
Q – 17 How do you maintain the document information of the test scripts?
Ans- Before creating a test, you can document information about the test in the General and Description tabs of the Test Properties dialog box. You can enter the name of the test author, the type of functionality tested, a detailed description of the test, and a reference to the relevant functional specifications document.
Q – 18 What do you verify with the GUI checkpoint for single property and what command it generates, explain syntax?
Ans- You can check a single property of a GUI object. For example, you can check whether a button is enabled or disabled or whether an item in a list is selected. To create a GUI checkpoint for a property value, use the Check Property dialog box to add one of the following functions to the test script:
button_check_info
scroll_check_info
edit_check_info
static_check_info
list_check_info
win_check_info
obj_check_info
Syntax:
button_check_info (button, property, property_value );
edit_check_info ( edit, property, property_value );
Q – 19 What is the use of Test Director software?
Ans- TestDirector is Mercury Interactive’s software test management tool. It helps quality assurance personnel plan and organize the testing process. With TestDirector you can create a database of manual and automated tests, build test cycles.
Q – 20 How you integrated your automated scripts from TestDirector?
Ans- When you work with WinRunner, you can choose to save your tests directly to your TestDirector database or while creating a test case in the TestDirector we can specify whether the script in automated or manual. And if it is automated script then
Q – 21 What are the different modes of recording?
Ans- There are two type of recording in WinRunner. i. Context Sensitive recording records the operations you perform on your application by identifying Graphical User Interface (GUI) objects. ii. Analog recording records keyboard input, mouse clicks, and the precise x- and y-coordinates traveled by the mouse pointer across the screen.
Q – 22 What is the purpose of loading WinRunner Add-Ins?
Ans- Add-Ins are used in WinRunner to load functions specific to the particular add-in to the memory. While creating a script only those functions in the addin selected will be listed in the function generator and while executing the script only those functions in the loaded add-in will be executed else WinRunner will give an error message saying it does not recognize the function.
Q – 23 What are the reasons that WinRunner fails to identify an object on the GUI?
Ans- WinRunner fails to identify an object in a GUI due to various reasons. i. The object is not a standard windows object. ii. If the browser used is not compatible with the WinRunner version, GUI Map Editor will not be able to learn any of the objects displayed in the browser window.
Q – 24 What do you mean by the logical name of the object.
Ans- An object’s logical name is determined by its class. In most cases, the logical name is the label that appears on an object.
Q – 25 If the object does not have a name then what will be the logical name?
Ans- If the object does not have a name then the logical name could be the attached text.
Q – 26 What is the different between GUI map and GUI map files?
Ans- The GUI map is actually the sum of one or more GUI map files. There are two modes for organizing GUI map files.
i. Global GUI Map file: a single GUI Map file for the entire application
ii. GUI Map File per Test: WinRunner automatically creates a GUI Map file for each test created.
GUI Map file is a file which contains the windows and the objects learned by the WinRunner with its logical name and their physical description.
Q – 27 How do you suppress a regular expression?
Ans- We can suppress the regular expression of a window by replacing the regexp_label property with label property.
Q – 28 How do you copy and move objects between different GUI map files?
Ans- We can copy and move objects between different GUI Map files using the GUI Map Editor.
The steps to be followed are:
1. Choose Tools – GUI Map Editor to open the GUI Map Editor.
2. Choose View – GUI Files.
3. Click Expand in the GUI Map Editor. The dialog box expands to display two GUI map files simultaneously.
4. View a different GUI map file on each side of the dialog box by clicking the file names in the GUI File lists.
5. In one file, select the objects you want to copy or move. Use the Shift key and or Control key to select multiple objects. To select all objects in a GUI map file, choose Edit – Select All.
6. Click Copy or Move.
7. To restore the GUI Map Editor to its original size, click Collapse.
Q – 29 How do you select multiple objects during merging the files?
Ans- Use the Shift key and or Control key to select multiple objects. To select all objects in a GUI map file, choose Edit – Select All.
Q – 30 How do you clear a GUI map files?
Ans- We can clear a GUI Map file using the Clear All option in the GUI Map Editor.
Q – 31 How do you filter the objects in the GUI map?
Ans- GUI Map Editor has a Filter option. This provides for filtering with 3 different types of options.
1. Logical name displays only objects with the specified logical name.
2. Physical description displays only objects matching the specified physical description. Use any substring belonging to the physical description.
3. Class displays only objects of the specified class, such as all the push buttons.
Q – 32 How do you configure GUI map?
Ans-
1. When WinRunner learns the description of a GUI object, it does not learn all its properties. Instead, it learns the minimum number of properties to provide a unique identification of the object.
2. Many applications also contain custom GUI objects. A custom object is any object not belonging to one of the standard classes used by WinRunner. These objects are therefore assigned to the generic object class. When WinRunner records an operation on a custom object, it generates obj_mouse_ statements in the test script.
3. If a custom object is similar to a standard object, you can map it to one of the standard classes. You can also configure the properties WinRunner uses to identify a custom object during Context Sensitive testing.
The mapping and the configuration you set are valid only for the current WinRunner session. To make the mapping and the configuration permanent, you must add configuration statements to your startup test script.
Q – 33 What is the purpose of GUI map configuration?
Ans- GUI Map configuration is used to map a custom object to a standard object.
Q – 34 How do you make the configuration and mappings permanent?
Ans- The mapping and the configuration you set are valid only for the current WinRunner session. To make the mapping and the configuration permanent, you must add configuration statements to your startup test script.
Q – 35 What is the purpose of GUI spy?
Ans- Using the GUI Spy, you can view the properties of any GUI object on your desktop. You use the Spy pointer to point to an object, and the GUI Spy displays the properties and their values in the GUI Spy dialog box. You can choose to view all the properties of an object, or only the selected set of properties that WinRunner learns.
Q – 36 Have you used WinRunner in your project?
Ans- Yes, I have been WinRunner for creating automates scripts for GUI, functional and regression testing of the AUT.
Q – 37 Explain WinRunner testing process?
Ans- WinRunner testing process involves six main stages: i. Create GUI Map File so that WinRunner can recognize the GUI objects in the application being tested ii. Create test scripts by recording, programming, or a combination of both. While recording.
Q – 38 What is contained in the GUI map?
Ans- WinRunner stores information it learns about a window or object in a GUI Map. When WinRunner runs a test, it uses the GUI map to locate objects. It reads an object’s description in the GUI map and then looks for an object with the same properties.
Q – 39 How does WinRunner recognize objects on the application?
Ans- WinRunner uses the GUI Map file to recognize objects on the application. When WinRunner runs a test, it uses the GUI map to locate objects. It reads an object’s description in the GUI map and then looks for an object with the same properties.
Q – 40 Have you created test scripts and what is contained in the test scripts?
Ans- Yes I have created test scripts. It contains the statement in Mercury Interactive’s Test Script Language (TSL). These statements appear as a test script in a test window. You can then enhance your recorded test script, either by typing in.
Q – 41 How does WinRunner evaluates test results?
Ans- Following each test run, WinRunner displays the results in a report. The report details all the major events that occurred during the run, such as checkpoints, error messages, system messages, or user messages. If mismatches are detected at checkpoints.
Q – 42 What is the purpose of regexp_label property and regexp_MSW_class property?
Ans- The regexp_label property is used for windows only. It operates behind the scenes to insert a regular expression into a window’s label description.
The regexp_MSW_class property inserts a regular expression into an object’s MSW_class. It is obligatory for all types of windows and for the object class object.
Q – 43 How WinRunner handles varying window labels?
Ans- We can handle varying window labels using regular expressions. WinRunner uses two hidden properties in order to use regular expression in an object’s physical description. These properties are regexp_label and regexp_MSW_class.
i. The regexp_label property is used for windows only. It operates behind the scenes to insert a regular expression into a window’s label description.
ii. The regexp_MSW_class property inserts a regular expression into an object’s MSW_class. It is obligatory for all types of windows and for the object class object.
Q – 44 When it is appropriate to change physical description?
Ans- Changing the physical description is necessary when the property value of an object changes.
Q – 45 When do you feel you need to modify the logical name?
Ans- Changing the logical name of an object is useful when the assigned logical name is not sufficiently descriptive or is too long.
Q – 46 How do you modify the logical name or the physical description of the objects in GUI map?
Ans- You can modify the logical name or the physical description of an object in a GUI map file using the GUI Map Editor.
Q – 47 How do you identify which files are loaded in the GUI map?
Ans- The GUI Map Editor has a drop down GUI File displaying all the GUI Map files loaded into the memory.
Q – 48 What different actions are performed by find and show button?
Ans- To find a particular object in the GUI Map file in the application, select the object and click the Show window. This blinks the selected object.
To find a particular object in a GUI Map file click the Find button, which gives the option to select the object. When the object is selected, if the object has been learned to the GUI Map file it will be focused in the GUI Map file.
Q – 49 How do you find an object in an GUI map?
Ans- The GUI Map Editor is been provided with a Find and Show Buttons.
To find a particular object in the GUI Map file in the application, select the object and click the Show window. This blinks the selected object.
To find a particular object in a GUI Map file click the Find button, which gives the option to select the object. When the object is selected, if the object has been learned to the GUI Map file it will be focused in the GUI Map file.
Q – 50 What is Boundary Test?
Ans- Boundary tests are designed to check a program’s response to extreme input values. Extreme output values are generated by the input values. It is important to check that a program handles input values and output results correctly at the lower and upper boundaries.
Keep in mind that you can create extreme boundary results from non-extreme input values. It is essential to analyze how to generate extremes of both types. In addition. sometime you know that there is an intermediate variable involved in processing.
If so, it is useful to determine how to drive that one through the extremes and special conditions such as zero or overflow condition.
Q – 51 the MSW_id value sometimes changes, rendering the GUI map useless
Ans- MSW_Id’s will continue to change as long as your developers are modifying your application. Having dealt with this, I determined that each MSW_Id shifted by the same amount and I was able to modify the entries in the gui map rather easily and continue testing.
Instead of using the MSW_id use the “location”. If you use your GUI spy it will give you every detail it can. Then add or remove what you don’t want.