RSS Feed

QTP Tutorial 1: Starting Testing using QTP / UFT

Quick Test Pro (QTP), later renamed Unified Functional Testing (UFT) is the industry leading automation product from Mercury Interactive. The other popular product from the Mercury Interactive stable was Win runner. However, due to better features offered by Quick Test Pro , Winrunner , which also has substantial features , was slowly and surely over taken over by QTP. In 2006 , Mercury Interactive was bought by HP (Hewlett Packard) and later QTP was renamed as UFT or Unified Functional testing. QTP or UFT is prominently used in Windows based environments . Here we shall try to understand how QTP/UFT works and how to use it for automating tests and how to write a framework so that maintenance becomes easier and volume of code becomes too big to maintain. However , we shall try to take topics one by one , in depth , so that we have no confusion left before progressing to the next topic. Begin… We assume that you have already installed UFT / QTP and have a license to use it . In this first tutorial we shall show how to start using QTP/UFT

  1. Start QTP / UFT by clicking the icon installed on the desktop or from program files
  2. After the license is   validated, the Add-in Manager Screen appears, which lets us select the add ins that are required. You may select all, but for the sake of performance, select only the relevant ones. For example if Oracle, Flex etc. are not there in your application do not select them.
  3. The start page appears once you click OK button
  4. Once the Start page appears, go to File – New test to create a new test
  5. The New Test window appears. Select “GUI Test”, give a name to the test, give a location to save it in and click the Create button.
  6. The workspace of the new Test appears as given below. Click the Action1 tab.
  7. You can also click the Action1 shown on the left side or Solution Explorer
  8. The Action workspace opens
  9. Click the Record button or the Record menu (F6)
  10. As the record button is clicked, the window given below comes up. Choose “Record and run test on any open browser” and click OK button. 11. QTP/UFT will start recording every single action that is performed on the chosen browser (you may choose other applications as well) and the following will get activated. The Stop button has to be clicked for stopping the recording 12.Perform the following tasks after opening Internet Explorer
  • Go to
  • Once the site opens, click the left side link ‘Music’
  • Click the left side link Sports
  • Click the left side link Gaming
  • Close the window by pressing Alt + F4
  1. You will see that the actions have been captured in QTP/UFT editor. Now make the script in the editor just as given in the below picture. Once done, save the script.
  2. If there is an error in the script, when the Save button is clicked, an error will be shown as given below
  3. Click the Run button. The script runs and the test pass

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: