Sie sind auf Seite 1von 10

QTP LIFE CYCLE

QTP life cycle contains six phases I. Test planning II. Generating the basic test III. Enhancing the test IV. Debugging the test V. Executing the test VI. Analysis the Results

I. Test Planning:
In this phase the automation test lead will do the following 1. Understanding the requirements 2. Identifying all the areas to be automated 3. Analyzing both the negative and positive flow of the application 4. Preparing the automation test plan document based on the analysis 5. Preparing the tool ready with all the pre configurational settings for the further operations

II. Generating the basic test:

In this phase the automation test engineer will generate the basic test engineer will generate the basic test for both the +ve and ve flow of the application

III. Enhancing the Test:


1. 2. 3. 4. 5.

One can enhance the script in the following ways

Inserting the check points Synchronizing the test Parameter sing the test (Data Driven Testing) Inserting the output value statements Inserting the transactional points for measuring transactions 6. Inserting the programmatic statements 7. Adding comments 8. Inserting the script statement manually

1. Check Point:
Checkpoint is defined as validation pointer test point which checks the objects state or bitmap state or data state during execution at any point of time Operational over view of checkpoint: Checkpoint works in two phases i.

Pre-execution Phase:
It captures the expected value

ii. While-execution phase:

Generates the corresponding test script statement It captures the actual value Compared the actual value with the expected value Displays the result

Types Of Checkpoints:
a. b. c. d. e. f. g. h. i. j. Standard checkpoints Bitmap checkpoint Text checkpoint Text area checkpoint Data base checkpoint XML checkpoint Page checkpoint Table checkpoint Hidden Checkpoints Image checkpoint Accessibility checkpoint

For Web Checkpoints

a. Standard Checkpoints:
Standard checkpoint is used for checking the standard GUI objects properties value , it can be inserted in two ways i. ii. Navigation through application: Keep the cursor in the desired location Keep the tool under recording mode Activate the menu item insert Go to checkpoint Select the option standard checkpoint Click on the desired object in the AUT Click on OK Select the desired properties to be checked Specify the desired expected values Click on OK Stop Recording Through application Through Active Screen

Navigation through active screen: Keep the cursor on the desired statement so that the corresponding snapshot is displayed in the active screen Go to active screen right click on the desired object Select the option insert standard check point Click on OK Select the desired properties to be checked

Specify the desired expected values Select one of the following options Select one of the following options o Before current step o After current step o Click on OK

b) Bitmap checkpoints: Bitmap checkpoint is used for checking the complete bitmap or a part of a bitmap. It can be inserted in two ways i. Through application ii. Through Active Screen Navigation through application: Keep the cursor in the desired location of the screen Keep the tool under recording mode Activate the menu item insert Select the option bitmap check point Click on the desired bitmap Click on OK If at all one need select a part of bitmap then select it using the select area button If at all one need save only the selected part then select the check box save only selected area Click on OK Navigation through Application: Keep the cursor on the desired statement so that the corresponding is displayed in the active screen Go to the active screen Right click on the bit map Select the option insert bitmap check point Click on OK If at all one need to select a part of bitmap then select it using select area button IF at all one need to save only the selected part select the check box save only selected area Select one of the following option o Before currant step o After currant step Click on OK (C). Text Checkpoint: Text checkpoint is used for checking the text present on a specified object. It can be inserted in two ways i. Through application ii. Through Active Navigation through application: Keep the cursor in the desired location of the screen Keep the tool under recording mode Activate the menu item insert

Click on check point Click on text checkpoint Click on the desired text Select the following option o Match case o Exact match o Ignore space o Text not displayed Click on OK

Navigation through Active Screen: Keep the cursor on the desired location so that the corresponding snapshot is available in the active screen Right Click on the desired position Click on insert text checkpoint Click on desired text Select the following option o Match case o Exact match o Ignore space Text not displayed Click on ok (d) Text Area Check Point: Test area checkpoint is used for checking the test presenting a specified area. It can be inserted only through the application but not through the active screen Navigation through application: Keep the cursor on the desired location of the screen Keep the tool under recording mode Activate the menu item insert Select the opinion text area checkpoint Select the exact area through cross hair pointers Choose the following options o Match case o Exact match o Ignore space o Text not displayed Click on OK Stop Recording

(e) Data Base Checkpoint: Data base check point is used for checking the contents of the data base Navigation: Activate menu item insert Go to check point Select the option data base checkpoint Select the option specify AQL statement manually Click on meet Click on create

Click on new Select the desired driver Slick on next Click on finish Click on select Select the desired database Click on ok Click on ok Click on ok Specify the designed query statement Click on finish Select the desired contents to be checked Select one of the following option o Before current step o After current step Click on ok

(f) XML Check Point: XML is a universally understandable language which is mainly used for data information Note: XML check point is used for checking the contents of an XML file Navigation: Activate the menu item insert go to check point Select the option XML check point Browse the desired XML file Click on OK Select the desired contents to de checked Select one of the following option o Before current step o After current step Click on OK (g) Table Check Point: This is used for checking the contents of a table Navigation: Keep the cursor on the desired statements, so that the corresponding page will be displayed in the active screen Go to active screen Right click on the page Select the option, Insert standard check point Select the desired table in the object hierarchy Click on ok Select the desired properties to be checked Select one of the following option o Before currant step o After currant step Click on ok

(h) Image Check Point:


This is used for checking the properties of an image

Navigation:
Keep the cursor on the desired statement, so that the corresponding page will be displayed in the active screen Go to the active screen Right click on the page Select desired image in the object hierarchy Click on ok Select on ok Select the desired properties to be checked Select the one of the properties to be checked o Before currant step o After currant step Click on ok

(i) Accessibility Check point:


Accessibility check point is used for checking the w3c standards (For web consortium standards) in order to confirm whether the page can be accessed all over the world or not

Navigation:
Keep the cursor on the desired statement sot heat the corresponding page is displayed in the active screen Go to the active screen Right click on the page Select one of the following options o Before currant step o After currant step Click on ok

2. Synchroniztion:
Synchronization is a process of matching the speeds of both the tool and the Application in order to keep them in sync with each other to obtain proper testing results Here the main concept is making the tool to wait till the application finishes its work it can be done in three ways 1. Inserting the synchronization point 2. Increasing the default time 3. Inserting the wait statement Navigation for inserting the synchronization point: Keep the cursor in the desired location Keep the tool under recording mode Activate the menu item insert Go to step select the option sync point Click on desired object Click on ok

Select the desired property Specify the desired property value Specify desired extra time Click on ok Stop recording In order to avoid above navigation one can directly type the statement in the desired location with the following syntax: SYNTAX: Object hierarchy. Wait propertyProperty name property value, extra time in milliseconds Example: Window (flight reservation).win button(delete order).wait propertyenabled,true,17000 Navigation for increasing the default time: Activate the menu item test Select the option settings Select the run tab Specify the desired time in milliseconds in the object synchronization time out field Click on apply and ok Syntax for Wait Statement: Wait (time in seconds)

Example: Wait (17)

Data Driven Testing: -

Data driven testing is a concept introduced in the automation in order to implement re- testing Collect the test data in to the data table Generate the basic test Parameterize the test Execute the Test Analyze the result

Steps to be followed to perform data driven testing:

Parameterization:

Parameterization is a process of replacing the constant values with parameters or variables in order to increase the scope of the test. Parameterize can be done in three ways 1. Through data driver wizard 2. Through key word view 3. Manually
Navigation through Data Driver Wizard:

Activate the menu item tools Select the option data driver Click on parameterize Click on next

Click on the parameter option button Select the desired column name Click on ok Click on next Click on finish Finally click on ok Go to key word view Select the desired constant value Click on configure the value button Select the option parameter Select the desired column name Click on ok

Navigation through Key word view:

To avoid the above navigation one can directly type manually as follows: A= datatable(v1,1) Vbwindow(form1).vbedit(val1).set A B= datatable(v2,1) Vbwindow (form1).vbedit(val2).set datatable(v2,1) Vbwindow(form1).vbbutton(Add).Click Vbwindow(form1).vbedit(res).check checkpoint(RES)
Navigation for parameter zings the check point:

Right click on the check point statement Select the option check point properties Select the option parameter Click on the parameter options button Select the desired column name Click on ok Once again click on ok

4. OUT PUT VALUE: Out put value is a feature provided by QTP, which is used for capturing a value from an application or from a database or from a XML file and stores it under specified column in the runtime data table
Operational overview of output value: -

The output value feature works in two phases 1. Pre-Execution Phase 2. While Execution Phase

1. Pre-Execution phase: It will capture the field name from which it need to capture the value It will generate the corresponding script 2. While-Execution phase: Captures the actual value from the field Stores it under a specified column in the run time data table
Types of Out Put Values:

There are five types of output values 1. Standard out Put Value: - It is used for capturing property value of a standard GUI object 2. Text out Put Value: - It is used for capturing the text present on a specified object 3. Text-Area out Put Value: - It is used for capturing the Text present in a specified area 4. Data Base Out Put Value: - It is used for capturing a value from the database 5. XML Out put Value: - It is used for capturing a value from the XML file
Navigation for Standard Output value through application:

Keep the cursor in the desired location Keep the tool under recording mode Activate the menu item insert Go to output value Select the option standard output value Click on the desired object in the AUT Click on OK Select the desired property to be captured Click on modify Specify the desired column name Click on Ok Once again click on ok Stop recording

Navigation For standard check point through Active Screen

Keep the cursor under the desired location Click on active screen

Right click on desired location Click on insert output value Click on ok Select the desired property Click on modify Specify the desired column name Click on ok Once again click on ok.

5. Inserting the transaction points for measuring the transaction: It is a concept introduced in QTP which is used for calculating the time taken by an application to perform a specific task or the execution time of a block of statement To do the same QTP has provided two options 1. Start transaction 2. End transaction
Navigation for inserting transaction points:

Keep the cursor in the desired location Activate the menu item insert Select the option start transaction Specify the transaction name Select one of the following option o Before currant step o After currant step Click on ok

To avoid the above navigation one can directly type the following statements manually in the desired location Services.start transactiontransaction name -------------------------------------------------------------------------------------------------------Services.end transactiontransaction name

Das könnte Ihnen auch gefallen