Qtp presentation

2,740 views
2,674 views

Published on

Published in: Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,740
On SlideShare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
241
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Qtp presentation

  1. 1. QuickTest Professional www.ramupalanki.com 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  2. 2. Introduction to Automation Testing <ul><li>What is Automation Testing ? </li></ul><ul><li>Benefits </li></ul><ul><li>Automation Testing Process </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  3. 3. QTP Testing Process <ul><li>Quick Test testing process consists of 7 main phases </li></ul><ul><li>Preparing to record </li></ul><ul><ul><li>Test Environment </li></ul></ul><ul><ul><li>Test Conditions </li></ul></ul><ul><li>Recording a session on your application </li></ul><ul><ul><li>Navigate according to Test Conditions </li></ul></ul><ul><li>Enhancing your test </li></ul><ul><ul><li>Adding logic and conditional statements </li></ul></ul><ul><ul><li>Parameterization </li></ul></ul><ul><ul><li>Inserting checkpoints </li></ul></ul><ul><li>Debugging your test </li></ul><ul><ul><li>Check that it operates smoothly and without interruption . </li></ul></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  4. 4. QTP Testing Process <ul><li>Run Test </li></ul><ul><ul><li>Check the behavior of your application </li></ul></ul><ul><li>Analyzing the test results </li></ul><ul><li>Reporting defects </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  5. 5. QTP Layered Architecture Logical name Physical Description Application Layer1 Layer2 Layer3 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  6. 6. QTP Window Expert 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  7. 7. Tree and Expert View Relation <ul><li>Test Objects hierarchy can be seen in both the TreeView and the Expert View </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  8. 8. Object Spy <ul><li>It is used to view object properties and Methods </li></ul><ul><li>Displays </li></ul><ul><ul><li>Object hierarchy tree </li></ul></ul><ul><ul><li>Run-time object methods </li></ul></ul><ul><ul><li>or test object methods </li></ul></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  9. 9. Object Repository <ul><li>Interface between QTP Script and the Application </li></ul><ul><li>Contains Logical Name and physical Description </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com Locate object in repository Find data-dependant property Parameterize property’s value
  10. 10. Recording Modes <ul><li>Normal recording </li></ul><ul><ul><li>Records the objects in your application and the operations performed on them. This mode is the default and takes full advantage of Quick Test’s test object model. </li></ul></ul><ul><li>Analog Recording </li></ul><ul><ul><li>Record the exact mouse and keyboard operations you perform in relation to either the screen or the application window. </li></ul></ul><ul><li>Low-Level Recording </li></ul><ul><ul><li>Record on any object in your application, whether or not Quick Test recognizes the specific object or the specific operation. </li></ul></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  11. 11. Enhancing Tests <ul><li>Parameterizing Test </li></ul><ul><li>Regular Expressions </li></ul><ul><li>Creating Checkpoints </li></ul><ul><li>Creating Output Values </li></ul><ul><li>Dividing Tests into Multiple Actions </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  12. 12. Parameterizing Tests To run the scenario with multiple sets of data. <ul><li>Steps for Parameterization </li></ul><ul><li>Defining a Data Table Parameter </li></ul><ul><li>Adding Parameter Values to a Data Table </li></ul><ul><li>Modifying Steps Affected by Parameterization </li></ul><ul><li>Running and Analyzing a Parameterized Test </li></ul>Demo……………….. 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  13. 13. Demo………….. <ul><li>How to provide the data to the respective Parameter through Tree View </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  14. 14. Demo………….. How to provide the data to the respective Parameter through Expert View 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  15. 15. Regular Expressions <ul><li>Regular expressions enable Quick Test to identify Objects and text strings with varying values. </li></ul><ul><li>User has to identify the data projected to be change, like dates, so to accepts any dates, user can use regular expression. </li></ul><ul><li>Example : </li></ul><ul><li>Actual Date format : </li></ul><ul><li>05/19/2004 (mm/dd/yyyy) </li></ul><ul><li>After Regular Expression: </li></ul><ul><li>[0-1][0-9]/[0-3][0-9]/200[0-9] </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  16. 16. Demo…… 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  17. 17. Demo…….. Click icon Do the changes as, shown below and select Regular Expression. QTP will take the year from 2000 -2009 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  18. 18. Checkpoints <ul><li>Used to check the current behavior of the application with the expected behavior. </li></ul><ul><li>Text /Text Area Checkpoint </li></ul><ul><li>Standard Checkpoint </li></ul><ul><li>Table Checkpoint </li></ul><ul><li>Page checkpoint </li></ul><ul><li>Database Checkpoint </li></ul><ul><li>Image Checkpoint </li></ul><ul><li>Accessibility Checkpoint </li></ul><ul><li>Bitmap Checkpoint </li></ul><ul><li>XML Checkpoint </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  19. 19. Text /TextArea Checkpoint <ul><li>checks that Current Text format with the Expected Text Format in a Web page or application window </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  20. 20. Table Checkpoint <ul><li>Checks information in a table </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  21. 21. Page checkpoint <ul><li>Checks the characteristics of a page </li></ul><ul><li>Check how long a Web page takes to load or if a Web page contains broken links. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  22. 22. Page checkpoint 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  23. 23. Database Checkpoint <ul><li>Used to check current Database data with the Expected Database data. </li></ul><ul><li>Check that the value in a database query is correct. </li></ul><ul><li>Demo……… </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  24. 24. Bitmap Checkpoint <ul><li>Checks an area of a Web page or application after capturing it as a bitmap </li></ul><ul><li>Check that a Web page (or any portion of it) is displayed as expected. </li></ul><ul><li>Demo…………. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  25. 25. Bitmap Checkpoint 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  26. 26. XML Checkpoint <ul><li>Checks the data content of XML documents </li></ul><ul><li>XML file checkpoints are used to check a specified XML file; XML application checkpoints are used to check an XML document within a Web page. </li></ul><ul><li>Demo…………. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  27. 27. XML Checkpoint XMLFile( &quot;Poem.xsl&quot; ).Check CheckPoint( &quot;Poem.xsl_2&quot; ) 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  28. 28. Image Checkpoint 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  29. 29. Accessibility Checkpoint 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  30. 30. Creating Output Values <ul><li>This is just reverse to the Parameterization, In this case QTP takes the data from the application and displays the same in the Data Table. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  31. 31. Creating Output Values Window( &quot; Flight Reservation&quot; ).WinEdit( &quot;Name:&quot; ).Output CheckPoint ( &quot;Name:_3&quot; ) 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  32. 32. Transactions <ul><li>A transaction represents the business process that you are interested in measuring </li></ul><ul><li>You can measure how long it takes to run a section of your test by defining transactions . </li></ul><ul><li>User can Plan the Scenario as transaction and use the Start Transaction and End Transaction while Recording. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  33. 33. Transactions Services.StartTransaction &quot;Start&quot; Services.EndTransaction &quot;Start&quot; 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  34. 34. Actions <ul><li>Actions help to divide Test Script into logical units </li></ul><ul><li>Usage : </li></ul><ul><ul><li>1)We can design more modular and efficient tests. </li></ul></ul><ul><li> 2)Actions enable you to parameterize specific components of a test </li></ul><ul><li> 3)Two or more tests can call the same action </li></ul><ul><li> 4)Complex tests may have many actions and may share actions with </li></ul><ul><li>other tests. </li></ul><ul><li>Example: </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  35. 35. Actions <ul><li>We can divide Test Script into multiple actions by creating </li></ul><ul><li>new actions or by inserting existing actions. </li></ul><ul><li>Kinds of actions: </li></ul><ul><li>Non-Reusable Action : An action that can be used only in the test in which it was created, and only once. </li></ul><ul><li>Reusable Action : An action that can be called multiple times by the test in which it was created (the local test) as well as by other tests. </li></ul><ul><li>External Action : A reusable action created in another test. External actions are read-only in the calling test. They can be modified only in the test in which they were created. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  36. 36. Creating New Actions <ul><li>We can add new actions to Test Script during a recording session or while designing Test Script. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  37. 37. Splitting Actions <ul><li>We can split an existing action into two sibling actions or into parent-child nested actions. </li></ul><ul><li>We cannot split an action and the option is disabled </li></ul><ul><li>when an external action is selected </li></ul><ul><li>when the first line of the action is selected </li></ul><ul><li>while recording a test </li></ul><ul><li>while running a test </li></ul><ul><li>when you are working with a read-only test </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  38. 38. Splitting Actions 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  39. 39. Inserting Existing Actions <ul><li>We can insert an existing action by inserting a copy of the action into Test Script, or by inserting a call to the original action. </li></ul><ul><li>Example: </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  40. 40. Inserting Existing Actions <ul><li>Copy of Action : It copied in its entirety, including checkpoints, parameterization, and the corresponding action tab in the Data Table . </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  41. 41. Inserting Existing Actions <ul><li>Calls to Actions: We can insert a call (link) to a reusable action that resides in your current test (local action), or in any other test (external action). </li></ul>Tree View Expert View 01/04/11 For more QTP Scripts, visit www.ramupalanki.com
  42. 42. Setting Action Properties <ul><li>The Action Properties enables to modify an action name, add or modify an action description, and set an action as reusable. </li></ul>01/04/11 For more QTP Scripts, visit www.ramupalanki.com

×