QTP Interview Questions and Answers

Last updated on Mar 15, 2022
  • Share
QTP Interview Questions

Quick Test Professional or QTP is a tool developed by Hewlett Packard (HP) to perform automated functional testing without any monitoring required after the script development. This software tool uses VBScript or Visual Basic Scripting to automate all its applications. The Scripting Engine required by QTP doesn’t need any installation as it’s pre-available in Windows OS. Here is a set of most used QTP interview questions for experienced as well as beginners to this niche selected by industry best recruiters.

Most Frequently Asked QTP Interview Questions

Here in this article, we will be listing frequently asked QTP Interview Questions and Answers with the belief that they will be helpful for you to gain higher marks. Also, to let you know that this article has been written under the guidance of industry professionals and covered all the current competencies.

Q1. What is object repository in QTP?

When the QTP program learns any new object, the program stores it in its object repository along with all its properties. QTP has two types of object repositories:

  • Local Object Repository: Linked to only one test, and easy to make changes and actions with it. Here objects are saved with .mtr extension.
  • Shared Object Repository: Can be used between multiple test cases, but no changes can be made here. Objects are saved here with TSR extension.
Q2. Mention the test steps of QTP.

QTP has a total number of five test steps which can be executed for any test case.

  • Test object identification
  • Test functions
  • Commenting
  • Session controlling steps
  • Programming logic
Q3. Explain the QTP test phases.

QTP can operate alone as well as can be work with the integrated environment.

QTP has the following phases:

  • Application analysis
  • Testing infrastructure preparation
  • Preparation of test cases
  • Test enhancement
  • And, defect reporting
Q4. How to handle Java tree in QTP?

The user has to select Java Add-In and launch QTP. Then the tester has to record operations on the Java Tree. If any issue appears while testing, the examiner can choose Tools > Object Identification > Java, tree object and make changes in assistive and mandatory properties to enable the identification.

Q5. How does QTP identify GUI object?

QTP identifies GUI object based on corresponding properties. At the time of recording, the tool will detect and store beautiful features in the GUI object’s object repository. It will compare the stored property values with the present on-screen properties to uniquely identify the GUI object.

Q6. What are the recording modes in QTP?

QTP tool supports three types of recording modes:

  • Contextual Recording Mode: It’s the default recording mode of QTP and recognizes test objects regardless of their on-screen position.
  • Low-level Recording Mode: It records the exact x,y coordinates of mouse operations, and useful in testing hashmaps and objects not identified by contextual mode.
  • Analog Mode: This records the exact mouse and keyboard movements that users perform about the application window.
Q7. Explain object spy in QTP.

An object spy is a tool present in QTP that helps testers to view the object operations and properties linked to then in AUT. The object spy can retrieve all the object properties and their values, and uniquely identify the objects with a set of features to store them.

Q8. Why is action split used by QTP?

Action split is used to split the actions in QTP to two parts.

  • Splitting into two sibling actions: The action breaks here are independent.
  • Splitting into parent-child nested action: This action is only conducted when the first action of parent gets executed.
Q9. Why we load add-ins in QTP?

Add-in is used to increase the capability of the tool. Then can be added as required to different scenarios, such as:

  • To enhance system capabilities
  • To load a particular function into the memory
  • To improve available graphics quality and communication interface
  • To access separate tasks that are needed for script execution
Q10. Mention the different actions types of QTP.

There are three types of actions that can be performed in QTP.

  • Reusable Action: Can be used multiple times from where they are stored.
  • Non-Reusable Action: Can be used a single time from where they are the store.
  • External Action: Reusable but stored in external tests. Available only in read-only mode.

The QTP tool supports various modern testing activities, starting from planning and creating a build to test execution, test analysis, and defect logging. As it’s one of the most business preferred testing tools available in the market, the demand of QTP professionals is also raising high. Further, in this content, we will discuss a set of most crucial QTP interview questions and answers for your acknowledgment.

Advantages of QTP
  • Comes with a user-friendly interface. Even non-programmers can add test cases into it quickly.
  • Contains advanced object identification mechanism and features to enhance existing tests without AUT through the active screen
  • Has an inbuilt IDE, which is easy to use and simple with the interface.
  • Easy and less time taking to maintain data and test iterations driving the test through configurations
Reviewed and verified by Best Interview Question
Best Interview Question

With our 10+ experience in PHP, MySQL, React, Python & more our technical consulting firm has received the privilege of working with top projects, 100 and still counting. Our team of 25+ is skilled in...