Skip to content

QTP Interview Questions

QTP Interview Questions and Answers

1. Explain the purpose of QTP.

Quick Test Professional or QTP is a record-playback test automation tool for graphical interfaces. QTP aids in testing web objects as well as ActiveX controls and can be used with any Java, Java applets, windows client, .NET framework, and Visual Basic web applications.

2. How can the recovery scenario manager be used to handle exceptions in QTP?

If unexpected errors and events occur during a test run, QTP provides a wizard through the Recovery Scenario Manger that can recover them.   A recovery scenario can be activated during 4 specific trigger events.  They include the following:

  • Appearance of a pop up window during test execution
  • The value or state change of an object’s properties
  • A failed test step
  • A failed test run in the application

3.    When creating functions, what should be done to allow optional arguments?

Since optional arguments are not supported a more indirect method must be employed. If an argument is not required, a blank string should be passed with a default value.

4.    When running a script, is it possible to turn off the results?

The window that displays the results can be suppressed but results will still appear in the log.  To do this, you must make sure that “View Results When Run Session Ends” is deselected in the Run tab of the options under the Tools menu.

5. What is the Test Fusion Report?

The Test Fusion Report contains the details of the test run.  This includes a high-level overview, the data used, application screenshots of discrepancies, a tree view of the failure points, and detailed explanations of each checkpoint.

6. What testing environments are supported by QTP?

All enterprise environments are supported for functional testing including .NET, J2EE, Java, Windows, Oracle, Siebel, SAP, Visual Basic, PeopleSoft, ActiveX, mainframe terminal emulators, and Web services.

7.    How does one go about changing an object’s run-time value?

During a test run the SetToProperty function can be used to change the property values that identify an object. This is only possible for properties that are included in the test object description.

8. What task does checkpoints perform?

Checkpoints are used to verify that the information that is expected is displayed while the test is running. There are eight types of checkpoints available:

  • Page – checks application characteristics
  • Text – verifies that text strings are show in the proper locations in the application
  • Object – checks the values of application objects
  • Image – checks the values of application images
  • Table – verifies information in an application table
  • Accessibility – checks the web page for compliance with Section 508
  • XML – verifies that the contents of XML data files or documents that are part of the application
  • Database – verifies the contents of databases accessed by your web site

Some more QTP Interview Questions

9.    Are object repositories required to for test case script?

An object repository is not required but you must know the window handlers.

10.         Name two ways that checkpoints can be added to an application?

One way is to add them while the application is recording.  The other is to use the Active screen (while it is active) to add them after recording is finished.

11. How you add a run-time parameter to a datasheet?

This can be achieved by using LocalSheet property. For example, the following is an example of how to return the local sheet of the run-time data table so that a parameter can be added: YourParam=DataTable.LocalSheet.AddParameter(“Date”, “6:30″)

12.         What does QTP use to identify application objects?

Objects are identified by class and by logical name.

13.         What does parameterize mean?

When a tester wants to verify how an application performs a certain operation, they will often run it several times using different sets of data. Instead of running the test several separate times, they can create a parameterized test that runs the operation several times using a different set of data each time.

14.         Describe the QTP test object model?

The test object model is a set of object classes and types that are used to represent application objects. Each object class contains a list of properties that identify objects of that class as well as a set of methods that can be recorded for it.

15. What are the object repositories modes?

There is two object repository modes: per-action mode and shared mode.   The per-action mode is best to use when creating simple record and run tests when there is only one or very few tests that correspond to the interface, objects, or application, when test object properties will not be modified frequently, and when creating single-action tests.  The shared mode is best used when there are several tests that correspond to the interface, objects, or application, when test object properties are expected to be modified frequently, and with multi-action tests.

16.         Describe the Object Spy.

Object Spy is a feature that can be used to view the properties of any of the application objects. When the pointer is used to select and object, the hierarchy tree, values, and properties of the object are displayed in the Properties tab of the Object Spy dialog box.

17.         How is batch testing performed in QTP?

Batch testing is performed by running the entire test set. All automated test scripts are executed one at a time by keeping the other scripts in waiting mode.

18.         Provide an example of how to use a COM interface in QTP?

A COM interface appears in the front and back end of a scenario.   If Oracle is being as the back end and Visual Basic as the front end, COM will create a more compatible interface.

Above listed are some of the important QTP interview questions for a tester job

Above are some of the Important QTP interview questions and answers.

Save on DeliciousDigg This
Submit to StumbleUponTweet

Leave a Reply