QTP Presentation
QTP Presentation
Automation:
It is a set of guidelines, assumptions and process developed in order to perform a task(s) in an effective, efficient and optimized way. A systematic approach for automating software applications.
tables and self-explanatory "keywords" to explain the actions to be performed on the application.
Software objects:
We call windows, WebPages, buttons, edit boxes, check boxes etc.. as software objects.
Types of Object in QTP: There are four types of object available in QTP. 1. Run time objects 2. Test objects 3. Utility objects 4. Automation objects/User defined objects.
Run time objects: The objects present in the AUT. Ex: Buttons, links, etc
Test Objects: References of Run time objects. Ex: WinEdit, WinButton, WebButton, etc Note: Test objects names vary from one environment to another
Ex.
Utility objects
They are QTP reserved objects used for testing and result reporting. Ex: 1. SystemUtil for launching/closing the application. 2. Reporter for defining results. 3. Services for inserting transaction points . 4. Environment for using environment variables.
Spying objects !!
For getting objects information, (Test objects names, property & Values) QTP is providing a feature called Object Spy, using this we can get objects information. Navigation>Tools>object spy>take hand icon & Show the object>get information (Object Spy shows the specific objects all available properties with their values) Note: As Object spy is an important feature, it can be available in 3 Areas.(1. In tools Menu 2. In local repository 3. In Repository manager)
ParentObject.Webedit(propertyname1&":="&property
value1).Set USR
Folder Structure
2) Scenario File An Excel file consisting list of all the Test scenarios possible in the application to be automated.
3) Test Case File Contains the detailed steps to be carried out for the execution of a test case It is also in the form of an excel sheet and contains columns for Keyword, Object Name, Parameter
4) Driver Script It Reads the scenario files and corresponding Test Case files. Checks the keywords and calls the appropriate utility script functions based on specific keyword. 5) Function Library: This folder contains two sub folders one is for storing common functions of our company, another folder for storing our project specific functions(.vbs).
scenario.xls
testcase.xls
Merits
The low cost for maintenance. In case of change only the
Test Case File needs to be updated and the Driver Script and Function will remain the same.
Enables to Begin to Develop Tests for a New Product or
Objects And Functions while Application Testers Focus on Maintaining The Test Structure and Design.
Demerits
The Development of "customized" Functions and