UFT Interview Questions

Last updated on Jan 09, 2024

QTP, called as UFT (Unified Functional Testing), gives functional and relapse test computerization for programming applications and conditions. It has a decent interest in the market in light of its graphical interface and backing for keyboard and scripting interfaces. Furthermore, it is extremely incredible in test information execution, test execution report, and article repository. Having QTP information will unquestionably give you an edge in getting a reasonable occupation in software testing. In this article, you can go through the set of frequently asked UFT interview questions and answers in the interview panel. There will be questions for beginners, at intermediate level and of experienced level. This will help you crack the interview as the topmost industry experts curate these at HKR training. Let us have a quick review of the most frequently asked UFT interview questions and answers. In case you're planning for an UFT interview, the data given will help you get ready.

Let's get started!

Most Frequently Asked UFT Interview Questions and Answers

Explain the logical name of the object?

Ans: Logical name is a name provided by QTP while making an item in the repository to exceptionally recognize it from different articles in the application. This name would be utilized by the QTP to plan the item name in content with its related portrayal in the article repository. For example, Browser("Browser").Page("Priya") . Here Priya is the logical name of the object. 

Explain the types of object Repositories in Micro Focus UFT.

Ans:

QTP Supports two sorts of Object Repository 

1) Shared Object Repository (Global) : It is utilized naturally. The extension for Per-Action is ".mtr" . 

2) Per-Action Object Repository, (Local) : It is best while managing dynamic items which are brought in numerous tests. The expansion is ".tsr"

Explain Object Spy.

Ans: Object Spy assists in deciding the run and test time object properties and techniques for the application under test.You can get to object spy straightforwardly from the toolbar or from the Object Repository Dialog Box. It is helpful during Descriptive Programming.

What is Test Fusion Report ?

Ans: Test Fusion Report shows all parts of a trial and is coordinated in a Tree design. It provides subtleties of each step operated for all iterations. It additionally provides a Run-time datatable, Screenshots and film of the trial run whenever picked.

Become a UFT Certified professional by learning this HKR UFT Training !

What is descriptive programming?

Ans: Ordinarily, an item and its properties should be recorded in the Object Repository to empower QTP to perform activities on it. You don't store the object and its property estimations in the Object repository yet notice the property estimation pair straightforwardly in the content while utilizing descriptive programming. The thought behind descriptive programming isn't sidestepping the article repository yet helps recognize dynamic items. 

Explain function of Text output value in QTP

Ans: Text Output value empowers you to catch text showing up on the application under test during run-time. If defined, text output esteems will catch values showing up in every cycle that would be put away in the run-time information table for additional examination. 

How do you call from one action to another action?

Ans: 

1) Call to copy of Action. - The Action Object Repository , Script and Database will be copied to the destination Test Script.

2) Call to Existing Action. - Object Repository , Script and Database won't be duplicated yet a call (reference) would be made to the Action in the source content. 

What is the keyword CreateObject?

Ans: 

This makes and returns a reference to an Automation object

SYNTAX: CreateObject(servername.typename [, location])

Arguments:

servername: Needed. The name of the application providing the object.

typename :  Needed. The type or class of the object to create.

location :  Optional. The name of the network server where the object is to be made.

For Example : Set IE = CreateObject("InternetExplorer.Application")

Explain the action split and purpose of using it in QTP?

Ans: Activity split is to separate a current activity into two sections.The objective is to isolate activities dependent on their usefulness to enhance code re-use. 

. Is it possible to switch between Per-Action and Shared Object Repository?

Ans: Yes, It is possible to switch. Go to Test>Settings>Resources. There you have to select the repositories option.

. Which of the environments are supported by HP QTP?

Ans: QTP supports the following environments like Web, SAP, Visual Basic, Siebel, Terminal Emulator, Java, .Net, Stingray, PowerBuilder, Delphi, and Web Services.

. Give the file extension of the code file in QTP.

Ans: script.mts

. What factors affect bitmap checkpoints?

Ans: Bitmap checkpoints are affected by screen resolution and image size.

. How do you handle Java trees in QTP?

Ans: You can choose Java Add - In and launch QTP. After that step, record the procedure on the Java Tree. On the off chance that you have an issue while recording, you can choose Tools > Object Identification > Java, tree object and make alterations required and assistive properties to empower ID.

. What is a Step Generator?

Ans: Step Generator empowers use to Add Test Steps in your content. By utilizing a step generator you can add steps to your content without really recording it. 

. How do QTP identify objects?

Ans: QTP recognizes any GUI Object dependent on its related properties. QTP will distinguish and store properties (as characterized in the Object Identification settings) in the article repository of the GUI object while recording. QTP will contrast the put away property estimations and the on-screen properties, to remarkably distinguish the GUI object at run-time.

. Give the benefits of Test Automation

Ans: 

  • Time: It creates fast outcomes 
  • No Manual intercession 
  • Financially effective 
  • Not inclined to human mistakes

. Difference between Keyword View and Expert View.

Ans: Keyword View is a symbol based view that displays test steps in tabular configuration. It consequently creates documentation for the test steps. Expert View provides the related VB Script articulation for each test step in the Keyword view.

. Explain Environment variables in UFT.

Ans: 

In UFT we utilize a couple of global factors to store the worldwide information like User Id, Password. Such worldwide factors are named as Environment factors. Through the assistance of these environment variables, the boundaries are characterized in the test scripts. These factors are utilized in different tests or activities.  We can store the links  to sites (URLs), testing environment subtleties, and so on.

The three types of environment variables in UFT are as follows:

  • Built-in (Read-Only)
  • User-defined – Internal (Read-Only)
  • User-defined – External (Read / Write)

The uses of Environment Variables incorporate:

. How to execute Cross platform testing and Cross browser testing utilising QTP?

Ans: Cross Platform Testing: Utilizing the Built in Environment Variable you can uncover the OS data. 

For example, Platform = Environment("OS"). At that point dependent on the Platform you require to call the activities that you recorded on that specific platform. 

Cross Browser Testing: Utilizing this code Eg. Browser("Core Values''). GetROProperty("version") you can extricate the Browser and its corresponding variant. 

For example, Internet Explorer 6 or Netscape 5. In light of this worth you call the activities which are applicable to that browser.

. What is Smart Identification?

Ans: On the off chance that the recorded portrayal doesn't empower QTP to recognize a particular object then QTP utilizes the "smart ID" method. It utilizes the accompanying extra properties to distinguish the object: 

Base Filter Properties : The arrangement of properties that can't be changed without changing the article type 

Optional Filter Properties : Additional properties which assist distinguish the article remarkably. 

. Explain QTP Automation Object Model.

Ans: The QTP Automation Object model works with Automation of QTP itself. Practically all arrangements and tasks given by QTP are addressed by QTP's Automation Object Model. All exchange boxes in QTP have a related computerization object that can be set or recovered utilizing the comparing properties or techniques in the Automation Object Model. QTP Automation Objects can be utilized alongside standard VB programming components like iterative circles or contingent explanations to aid you plan a content of decision.

. What is the run time data table?

Ans: Information like parameterized output, checkpoint values, output values  are stored in the Run-time Table. It is an xls file that is put away in the Test Results Folder.  It can be availed in the Test Fusion Report.

. Explain the types of Actions in QTP?

Ans: 

  • Non-reusable action: An activity which can be called uniquely in the test with which it is put away, and can be called just a single time. 
  • Reusable action: An activity which can be called on various occasions by the test through which it is put away just as by different tests. 
  • Outer action: A reusable activity put away with another test. External actions are read only in the calling test, yet you can decide to utilize a local, editable duplicate of the Data Table info for the outer activity.

. What is a Procedure or Subroutine in VB Script?

Ans: Sub procedure is a progression of VB Script explanations (encased by Sub and End Sub statements) which execute activities yet don't restore a value. A Sub technique can accept arguments (constants, factors, or articulations which are passed by a calling strategy). On the off chance that a Sub methodology has no arguments, its Sub assertion should incorporate an empty arrangement of parentheses( ).

UFT Training

  • Master Your Craft
  • Lifetime LMS & Faculty Access
  • 24/7 online expert support
  • Real-world & Project Based Learning

 

. What is Round function in UFT?

Ans: 

Round function in UFT is used to round the decimal For example

Mydecimal = 6.3433333

Rounded Value= Round(Mydecimal , 3)

Print rounded value,  it will print 6.343

. What is the contrast among extraction and exit iteration?

Ans: Exitaction is utilized when we need to exit from a specific action, while exit iteration is utilized to exit from a specific action cycle of an action.

. What is the Error Pane of UFT?

Ans: While dealing with contents like executing, saving, opening the contents and so forth, we may confront not many errors. Such mistakes are recorded and shown in a location called ‘Error Pane’. 

The different types of errors listed in Error Pane are:

  • Code syntax errors
  • Missing resources
  • Missing references and property values

. Explain Output Value step

Ans: An Output Value step is utilized to catch the value from any field or estimation of any object property when the content execution is going on. Furthermore, such values are put away in the ideal area in the datatable and can be utilized as an input for different fields or articles at another point in the test content. 

The four types of output values are:

  • Standard Output value
  • Text or Text Area Output Value
  • Database output value and
  • XML output value

. Explain how functions are different from actions.

Ans: Functions are not related with Object Repository and Data Table though Actions keep up their own Object Repository and Data Table. Functions are components of VB scripting which are not just limited to UFT though Actions are components of UFT. The code gets re-utilized with the assistance of capacities, and with actions, the test gets re-utilized. The normal element among functions and actions is that both are related with yield boundaries, input parameters, and return values back. A Script can be separated into numerous Actions like Sign In, Sign Out, and so on, though Function is made in a script. 

. Is it conceivable to utilize two instances of UFT on a similar machine? If not why?

Ans: No, we can't utilize two instances of UFT on a similar machine. UFT manages numerous occurrences of the application that will be tested. We can even operate on two distinct applications on a similar machine ceaselessly the recording of UFT. You require to alter a couple of design settings of the UFT for this.

You are required to choose the option “Record and Run on any opened application” from Automation -> Record and Run settings -> select.

. Different types of Test Automation Frameworks.

Ans: 

1) Linear Scripting - Record & Playback

2) The Test Library Architecture Framework.

3)The Data-Driven Testing Framework.

4)The Keyword-Driven or Table-Driven Testing Framework.

. Distinction between Bitmap Checkpoint and Image Check point?

Ans: A Bitmap designated spot executes a pixel to pixel correlation of a picture or part of a picture. Image Check point does a pixel to pixel correlation however rather think about picture properties like alt text, destination url and so on. 

. What are the types of recording modes in QTP

Ans: 

  • Ordinary Mode is the default recording mode and utilizes QTP's Test Object Model. It perceives objects paying little heed to their situation on - screen. This is the favored method of recording and is utilized for the vast majority of the mechanization activities. 
  • Low-level recording mode records the specific x,y coordinates of your mouse activities. It is useful in analysing hashmaps. It is valuable for recording objects not distinguished by ordinary methods of QTP. 
  • Analog mode records precise mouse and keyboard movements you execute comparable to the screen/application window. It is helpful for the activity, for example, drawing an image, recording sign, drag and drop tasks.

. Explain virtual objects.

Ans: Your application might include objects which act like standard articles however are not perceived by QTP. You can characterize these objects as virtual objects and guide them to standard classes, for example, a check box. QTP copies the client's activity on the virtual object during the executing time. In the test outcomes, the virtual object is shown like it is a standard class object. Assume you need to record a test on a Web page including a bitmap which the client clicks. The bitmap includes a few diverse hyperlink zones, and every territory opens an alternate destination page. At the point when you record a test, the Web website coordinates the directions of the snap on the bitmap and opens the required page. To empower QTP to click at the necessary coordinates during an execution, you can characterize a virtual object for a zone of the bitmap, that incorporates those directions, and guide it to the button class. QTP taps the bitmap in the territory characterized as a virtual item with the goal that the Web website opens the right destination page when executing a test.

. Differentiate the kind of test cases that can be computerized and which can't be robotized.

Ans: 

  • We can't robotize the Test Cases which require human impedance. 
  • The recently planned Test Cases are not robotized. In any event once they ought to be executed physically. 
  • Tests that should be executed more than once ought to be robotized. 
  • Tests that should be tested with numerous arrangements of information are robotized. 
  • Text cases dependent on the prerequisites which change over and over can't be computerized.

. Give the differences between Selenium and HP UFT

Ans: 

  • Selenium is an open-source apparatus though UFT isn't. Selenium doesn't need any permit to utilize it anyway UFT needs it. 
  • UFT bolsters just VB Scripting though Selenium scripting should be possible utilizing JAVA, Perl, .net, PHP, and so on. 
  • Utilizing UFT we could  test windows based, and centralized computer applications. Yet, Selenium is utilized to test just web applications. 
  • Testing through UFT is over the top more expensive than testing with Selenium. 
  • UFT contents are more easy to use than Selenium Scripts.

. Explain the types of Automation Framework in UFT?

Ans: 

To facilitate the interaction of test automation utilizing UFT, test robotization is planned. There are basically three types of computerization systems in UFT 

  1. Keyword Driven Framework: It is utilized when numerous functionalities should be tried. 
  2. Information Driven Framework: It is utilized to test the same flow with various test information, test information is given more significance than multiple usefulness of app.
  3. Hybrid Framework: It is a blend of information driven system and keyword.

. How might you handle special cases in QTP?

Ans: 

In QTP Exceptional dealing with is finished by utilizing 

  • Recovery Scenarios. 
  • Utilizing "On Error" statement

In Recovery situation you need to characterize. 

  • Triggered Events.
  • Recovery steps.
  • Post Recovery Test-Run.

At Script Level you can utilize the On Error Resume Next and On Error Go to 0 statement.

. Disadvantages of QTP?

Ans: As of QTP version 10

Huge Tests in QTP take lots of memory and increase CPU utilization.

Since QTP stores outputs in an HTML file (and not text) the result folder becomes big.

. How will you add synchronization points in QTP?

Ans: There are 4 different ways through which we can add synchronization focuses in QTP 

  • Wait statement : This assertion will stop the execution for x seconds until the object comes up. 
  • Wait property : This strategy will stand by until the article takes specific worth. 
  • Exit statement : This assertion will stand by until the object opens up. 
  • Sync technique: The code will stand by until the browser page is totally stacked. For web application testing this technique is utilized. 

. In QTP, clarify what is the qrs file?

Ans: qrs signifies "Quicktest Recovery Scenario". By utilizing recuperation scenario managers we can deal with special cases in test execution. In QTP when you make a recovery situation, you should save it in the .qrs file. qrs file might have quite a few situations characterized in it.

. What is an Optional advance in QTP? How can you add an optional step in QTP?

Ans: When executing a test, it comes up short in opening a dialog box, QTP doesn't really cut short the trial. It passes any progression assigned "optional" and keeps executing the test. Naturally QTP consequently checks as discretionary advances that open certain discourse boxes. To set an optional advance in the keyword, right snap and select "optional Step". The symbol for the optional step would be added in the subsequent stage. In the expert view to add optional advance, add optional step to the start of the VBScript statement.

 Want to know more about UiPath,visit here UFT Tutorial !

Subscribe to our YouTube channel to get new updates..!

 

. Explain the Checkpoints in UFT

Ans: Check Point addresses where a specific condition or estimation of an object is checked against some other fixed or ongoing value. Checkpoints can be embedded anytime in the test script. UFT upholds different sorts of checkpoints. 

  • XML Checkpoint – It is utilized to check the data related to XML.
  • Standard Checkpoint – This checkpoint is utilized to confirm the object properties of buttons, lists etc.
  • Text Area Checkpoint – It analyzes whether the content is shown in the predefined territory or not.
  • Bitmap Checkpoint – It analyzes the specific zooming property of the pictures.
  • Database Checkpoint – It is utilised to analyze the database values.
  • Image Checkpoint – It analyzes the properties of pictures.
  • Text Checkpoint – It analyzes the position of the text at a particular place.
  • Table Checkpoint –  It analyzes the details of tables like row height, width etc.Accessibility Checkpoint – It analyzes the standardization of the websites.
  • Page Checkpoint – It analyzes the properties of a web page like the number of hyperlinks and images in a webpage, the time is taken for loading the page, etc.

. What are the features that UFT supports?

Ans: The features that UFT supports are 

  • Direct Features – Features that are implicit with a UFT device window like Data Table, Object Spy, Step generator and so on. 
  • HP Integrated Tools – These devices can be naturally installed if the UFT is introduced. For example: Test Batch Runner, Password Encoder, and so on 
  • Other Integrated Tools – If we need to utilize these devices, at that point a client needs to install them. For example: VB Script, SQL and so on.

. Explain Canvas view of UFT.

Ans: Canvas is a presentation board, which shows the graphical type of activities of the test flow that occurs during the testing cycle. According to our necessities, we can alter the actions from the start to end. 

. What is the purpose of executing the scripts in Hidden-mode in UFT?

Ans: A client can really run the test contents of UFT in Hidden-mode. Running the test contents in this mode will enhance the execution and its fastness. As User intercession isn't needed during the execution of contents this shrouded mode can be utilized easily. The test outcomes can be seen by the client after the content execution gets finished. To empower this hidden mode, go to "Remote Agent Setting" and choose the "Run UFT in hidden mode" option.

. Explain Distributed testing.

Ans: Distributed Testing means analyzing the application on numerous servers, machines, clients, mobiles, and so on. UFT upholds this distributed testing using a new characteristic called “Run-time engine”.

. What is an Accessibility Checkpoint?

Ans: World Wide Web Consortium (W3C) thought of certain directions and rules for Web-based innovation and data frameworks to make it simple for the disabled to get to the web. For instance the principles make it compulsory to have an 'alt text' for a picture. So a visually impaired individual who is getting to the site, will utilize text - to - speech converters and at least comprehend what the picture is about. Every one of these principles are analysed by Accessibility Checkpoints. 

. Which method in QTP gets the property values of a run-time object?

Ans: The GetRoProperty method gets the property values.

. List out the properties of ADODB

Ans. The following are the various properties of ADODB.:-

  • ADODB.Connection - Useful for building database connections.
  • ADODB.Fields - This property is helpful to fetch the specific columns from the record set after query execution. 
  • ADODB.Command - Helpful in executing an SQL command.
  • ADODB.Recordset

 

. Define Action Conversion Tool.

Ans. QTP/UFT provides an in-built tool that helps to transform various actions into business process components.

. What extension is helpful for the Function Library in QTP?

Ans. ".QFL" is the helpful extension for the function library in QTP.

. How to check the Broken Links within an application?

Ans. By including the Page CheckPoint in the application pages, we can verify the broken links within the application. It allows us to check the total number of valid and invalid links available on a page.

. Define SetToProperty.

Ans. This property helps to make changes to the properties of an object stored inside the Object Repository. These are only for temporary changes.

. Define the benefits of a Data-driven Framework.

Ans. The benefits of the data-driven framework include less code generation, minimizing the cost of new test addition, developing test data, etc.

. How does QTP itself automate?

Ans. QTP itself automates through the COM interface offered by HP-QTP.

. How do you create object descriptions within QTP?

Ans. Descriptive programming is used to create an object's description.

UFT Training

Weekday / Weekend Batches

 

. Define the way to create a TSR file in UFT.

Ans. TSR refers to Test Shared Repository, built to share object repositories. The below steps will help you to create a TSR file within UFT.

  • Start with opening the Object Repository.
  • Open the "File" menu.
  • Then move to the "Export local objects" tab and select the same.
  • Later a dialog box will appear where you need to save the .tsr file. You have to provide the required path to store the file. Like this, you can create a TSR file within UFT.

. What is the use of the SetSecure method in UFT?

Ans. SetSecure is a helpful method to set the encrypted password where we securely set the text within the password.

. List out the different types of Errors handled in UFT.

Ans. One can experience the following three error types while using UFT.

  • Logical Errors
  • Syntax Errors
  • Runtime Errors

. What is the way to open a read-only Shared Object Repository (SOR) within QTP?

Ans. We must choose the "Enable Editing" option within the object repository manager option to open a read-only Shared Object Repository (SOR). In QTP, the Shared Object Repository is default read-only.

. What is the way to modularize a script in QTP?

Ans. We can add library files to the QTP script to modularize the script.

. Define the use of the keyword

Ans. It is used when we need to state that we must declare a variable before using it within the QTP.

. How can you find an array's length in UFT?

Ans. To find the array's length in UFT, we can use the UBound function. It returns the largest subscript for the dimension stated for the array in UFT.

About Author

As a senior technical content writer for HRK tainings, srivalli patchava has a greater understanding of today's data-driven environment, which includes key aspects of data management and IT organizations. She manages the task of creating great content in the areas of software testing, DevOps, Robotic process automation. Connects with her on Linkedin and Twitter.

Upcoming UFT Training Online classes

Batch starts on 23rd Mar 2024
Mon - Fri (18 Days) Weekend Timings - 10:30 AM IST
Batch starts on 27th Mar 2024
Mon & Tue (5 Days) Weekday Timings - 08:30 AM IST
Batch starts on 31st Mar 2024
Mon - Fri (18 Days) Weekend Timings - 10:30 AM IST
To Top