Learn UFT or QTP Step By Step

Spread the love
  • 1

Learn UFT or UFT Step By Step
Learn UFT or UFT Step By Step
Learn UFT or UFT Step By Step

Learn UFT Step By Step:

The topics we must cover while learning UFT are as follows:

  • Why we need to use UFT?
  • Features of UFT
  • Assets of UFT with extensions.
  • How to work with UFT?
  • How to plan a Test?
  • How to understand UAT?
  • Configure and types of Licenses.
  • Install and Configure Add Ins
  • How to create your test in UFT?
  • Recording modes of UFT.
  • Object Repository concept
  • Functions and Sub procedures in UFT
  • How to use comment in UFT?
  • Object identification process
  • Step Generator
  • Datatypes in UFT
  • Variables in UFT
  • Looping and conditions in UFT
  • How to enhance Test?
  • Things to know of VBScript
  • Function Library concept in UFT
  • Synchronization concept in UFT
  • Actions in UFT
  • How to Parameterize your test?
  • How to work with Utility object?
  • How to work with checkpoint?
  • How to work with output values?
  • How to work with reporter Object?
  • How to write custom HTML file?
  • Test Batch Runner
  • What is automation framework?
  • Introduction to Dictionary Object
  • Introduction to File System Object.
  • Difference between Action and Function
  • How to debug UFT script in VBscript debugger?
  • Errors and error handling of VBScript
  • Regular expression in UFT
  • Transactions in UFT
  • How to capture ajax events in UFT?
  • How to use Optional step in UFT?

Why UFT not Selenium?

UFT is a closed source software from HP. Many engineering brains are working the product better. Hence we need license to use it. However selenium is open source and there are not much engineers active supporting this. That does not mean it is bad.

While there lot of official help on same topics available directly from HP, Selenium lacks on that space. Testers need to try and find out the best solution.

UFT uses old VBscript hence ramping up from manual testing to UFT is easy but selenium needs knowledge on java,perl or .NET to write effective code.

Easy recording is available for UFT where as Selenium does not have easy recording. We need to code from scratch.

UFT supports almost all known technologies whereas selenium supports web technology.

Lastly UFT is very much user friendly,selenium lacks in this space.

First Step to UFT

The first thing you need to learn is VBScript…the basics..The best place to learn VB script is —MSDN

Technology Supported by UFT:


Licenses of UFT:

UFT provides three types of licenses:

  1. Trial with limited facilities
  2. Seat License- tagged to the machine
  3. Concurrent License- depends on number of users

What is a VBScript to a Automation Test Engineer?

VBScript (Visual Basic Script)

1. It is a scripting language scaled down version of Visual Basic
2. It runs on client side.
3. Basically a syntax based language. Most VB syntaxes run on this.
4. For our purpose we always save the file as “XYZ.vbs”

How to Work with UFT?

How to work with QTP is a systematic process. Lets us go through one by one….

Analyzing the application

In this phase we check what kind of application on which tests needs to be performed. If required we need to add the add ins or we need to buy the add ins.

Selecting Areas/Test Cases for Automation

After successful pass of step-a we will identify the manual testcases or the scenarios that we can automate. We can not automate 100% of the application in general.

Planning (Effort estimation, Schedule, Work allocation and Automation Framework implementation)

We will do a effort estimation for Step-b. We will also consider the schedule,framework effort in this phase.QTP records raw lines of codes.So transferring those from code to framework or add to existing framework is an effort.In the last phase we will identify the team members and allocate them the work.

Creating Generic and project specific functions

While recording we might get some generic function like button press..it is common to all the window/pages…this can a be a good tricks to write a small function on button press and can reuse them.Or we might get a new flow which is very specific to a business.

Creating required Automation resources (Functions, Object repository Files, Environment variable files—etc)

This is as per organization test strategy.If test strategy says we need to do record playback then it is ok to record and store objects in object repository or else we will go descriptive programming.

UFT Function and Sub Procedure

UFT allows all to run same and repetitive tasks in the form of functions which can return some value and sub procedure which does not return any value.

Object Repository in UFT:

Refer this article to get Object repositories in UFT.

Introduction to File System Object(FSO)

FSO provides us the ability to work with files and folders. FSO will also covers on how to work with folders.

Data Types in UFT

UFT supports VBScript Data types.

Variables in UFT

UFT supports VBScript variable concept.

Creating Tests (Using Object Repository or Descriptive Programming)

Automation process Using UFT

The automation process is the basic building block of UFT test cases. The Automation testing via UFt consists of the following processes:

  1. Prepare for recording.
  2. Actual recording
  3. Enhancing test script.
  4. Debugging
  5. Analyze the result
  6. Reporting

Recording in UFT

Recording is the fundamental process of building the test script.

Preparing for recording:

Before we start hitting the recording button, we need to make sure the application is stable and the object is constantly visible for recording to happen.

Before you start recording it is always better to close all other applications or web pages.

In Record and Run settings we can define if we want some default application to open during recording similarly for web , in web tab we can define if some predefined webpage we want to open.

After the recording you can use stop recording button to stop recording.

Recording in UFT

As and when, we navigate through the application or web pages using UFT recording, UFT will mimic the same steps in keyword view and expert view. In keyword view the steps will come as rows and columns and in expert view, it will come as plain code.UFT supports 3 recording mode to combat different scenarios.

Understand the recording

Once you have completed the recording in UFT the keyword view will be like below:

Don't miss out!
Subscribe To Newsletter

Receive top technical news, lesson ideas, travel tips and more!

Invalid email address
Give it a try. You can unsubscribe at any time.

Spread the love
  • 1



Please enter your comment!
Please enter your name here