Pages

Friday, 22 June 2012

Recording Modes in qtp

Three types of recording modes
1.Standard Recording(Default)
2.Analog recording
3.Low level recording
Standard recording
Records the test in terms of GUI objects
Records the objects in your application and the operation performed on them
This mode is the default and taken full advantage of qt test object model

Navigation:Automation->Record
or
Select Record option on automation tool bar
or
Short cut key F3

Analog Recording

Enables you to record the exact mouse and keyboard operation you perform in relation to either the screen or the application window
 Navigation:Keep Tool under Recording mode

Automation->Analog Record
or
Short cut key SHIFT+ALT+F3
VBSCRIPT stmt
window(“Microsoft Internet”).RunAnalog “Track1”
The  track file called by the run analog method contains all your analog data and is stored with the action

Low Level Recording
This mode record at the object level and records all runtime objects as window(Generally Multimedia Purpose)
 Navigation:Keep Tool under Recording mode

Automation->Low Level Recording
or
Short cut key CTRL+SHIFT+F3
 
Disadvantages of recording
1.It occupies a lot of memory space(due to duplicate objects),so QTP performance will be reduced
2.No Centralized Maintenance mechanism, So Modifications are very difficult
3.User may not have command on the Recorded Script, So locating errors is difficult
4.Recorded scripts are QTP internal files, they may corrupt

Advantages
1.It is used for analyzing the AUT in the initial stage to find out weather the Qtp tool is recognizing all of our application objects or not

2.It is easy to create/test scripts
3.It is used for frequently changing UI
4.It takes less time to create tests

Quick Test Main Window

This is divided into 8 parts
1.Menu Bar
2.Tool Bar
3.Test Flow Pane
4.Test Pane
  4.1Expert View
  4.2Keyboard View
5.Data Table
6.Active Screen
7.Debug Viewer
8.Missing Resources pane
1.
Menu Bar
Displays menus of Quick Test
cmds File,Edit,View,Insert,Automation etc.,
2.
Tool bar
Displays icons/images for all QT
cmds or sub menus
3.
Test Flow Pane
Displays the hierarchy of actions and action calls in the current test and shows the order in which they are run

4.Test Pane
4.1Expert View
In the expert view ,QT displays each step as a Vbscript line or stmt
Web Application
1.1.Object description displays a parenthesis
Browser(“Testing School”);
Browser(“Lantic”);
1.2 Object Hierarchy
Seperated by Dot)
Browser(“Lantic”).Page(“School”)
Browser(“Lantic”).page(“
lantic”).frame(“customer”)
1.3 operation or method
Always displays at the end of the sheet, Followed by any values associated with the operation
Browser(“Lantic”).page(“Lantic”).webedit(“Username”).set(“admin”)
Browser(“Lantic”).page(“Lantic”).webedit(“UserId”).set “Lantic”
4.1.2 Desktop/Window Application
Dialog(“Login”).Winedit(“Agent Name”).set “admin”
Window(“Flight Reservation”).WinButton(“Flight”).click
4.2.Keyword View
  In the keyword view,QT displays information about each step and shows the object hierarchy in an icon based table
The Columns in the keyword view show different information for each step as follows



1.Item
Test Object function call in a hierarchy icon based tree
2.Opeartion
Operation to be performed on the items
ex: click/select/set
3.Values
Test data or input data
4.Documentation
Description of the steps/Auto documentation as what the steps does
ex: Enter “test” in the username edit box
5.Datatable
It is used to store data and parameterize that data to the test script
there are two sheets by default. they are
1.Global 2. Action1
In data table we can have 256 sheets. out of 256 sheets ,one sheet is Global and 255 sheets Action sheets
Global sheet related to all the tables
Action sheet related to corresponding action only

6.Action screen
Provides a snapshot of your application as it appeared when you performed a certain step during the recording session
Advantages
Easy to insert check points/out put values
Easy t add objects to object Repository
Easy to insert steps
Easy to understand script by observing images in the active screen area
7.Debug Viewer
It  is used for viewing, modifying or setting the current values of variables or objects during test execution break with the help of three
tabs.watch,command,variable
8.Missing Resources Pane
Whenever we run a test, the files which are associated with the test are missed/moved , the missing resource pane will be opened automatically and displays the information about that missed file

The missing resource pane may list any of the following types of missing resources
Missing Action name
Missing Object repository
Repository Parameters
Missing Environment Variables
Missing library