Types of Recordings and Checkpoints in QTP

In our last post we had discussed about advantages of QTP over other testing tools, basic settings, keyword view and expert view. Let us now discuss about the different types of recordings in QTP.

There are three types of recordings in QTP:

I. Normal Recording:

This is the default mode in QTP. It recognizes the objects in the application regardless of their location on screen.

For recording just click on Record button in QTP and start recording.

II. Analog Recording:

In this recording QTP records and tracks every movement of the mouse as you drag the mouse around a screen or window.

For recording:

1. Make sure the application is open and on the correct page where the recording has to be done.

2. Click on Record button in QTP (If QTP window does not restore down, click on the Restore Down button in between the minimize and close button on the right side corner of the screen).

3. Move the QTP window so that the RECORD, PLAY and STOP button are exactly on the address bar and leave it there.

4. Go to Automation -> Analog Recording.

5. In Analog Recording setting window select the second radio button which states “Record relative to the following window”.

6. Click on the button next to Window Title which has the hand sign on it.

7. Move the cursor to the application window and click on the Browser name on top of the browser.

8. Click on ‘Start Analog Record’ button on Analog Record Setting window.

9. Record the necessary step and then click on Stop button in QTP.

III. Low-Level Recording:

In this recording, QTP records the object in terms of its X and Y coordinators on the screen.

For recording:

1. Make sure the application is open and on the correct page where the recording has to be done.

2. Click on Record button in QTP (If QTP window does not restore down, click on the Restore Down button in between the minimize and close button on the right side corner of the screen).

3. Move the QTP window so that the RECORD, PLAY and STOP button are exactly on the address bar and leave it there.

4. Go to Automation -> Low Level Recording

5. Record the necessary step and then click on Stop button in QTP.

Checkpoints:

A checkpoint is a verification point that compares the current value for specified properties with the expected value for those properties. This enables you to identify whether your application is functioning correctly or not.

We will discuss the steps for adding Standard checkpoint and Text Area checkpoint.

Standard Checkpoint:

It checks the property value of an object in the application. It compares the expected values of object properties to the object’s current values during a run session

Steps for adding Standard checkpoint through Active Screen:

1. Open the QTP script in which the checkpoint needs to be added.

2. In QTP script click on the specific line where you want to add the checkpoint.

3. Make sure the Active screen window is displayed in QTP (If not navigate to View->Active screen).

4. After clicking on specific line the active screen window will display the screen of the application.

5. In active screen go to the specific object you need to test and right click on that object.

6. In the pop up menu list click on the first name which states “Insert Standard Checkpoint…”

7. The Object Selection – Checkpoint Properties dialog box opens.

8. Select the item you want to check from the displayed object tree.

9. Click on OK button. The Checkpoint Properties dialog box opens.

10. Specify the settings for the checkpoint (select the specific checkbox which needs to be checked for e.g. for a link ‘innertext’ or ‘text’ checkbox should be selected).

11. Click OK button to close the dialog box. A checkpoint statement is added for the selected object.

Standard Output Value Checkpoint:

Standard output values is used to output the property values of most objects.

Steps for adding Standard Output Value checkpoint through the Active Screen:

1. Open the QTP script in which the checkpoint needs to be added.

2. In QTP script click on the specific line where you want to add the checkpoint.

3. Make sure the Active screen window is displayed in QTP (If not navigate to View->Active screen).

4. After clicking on specific line the active screen window will display the screen of the application.

5. In active screen go to the specific object you needs to test and right click on that object.

6. In the pop up menu list click on the second name which states “Insert Output Value…”

7. The Object Selection – Output Values Properties dialog box opens.

8. Select the item you want to check from the displayed object tree.

9. Click on OK button. The Output Value Properties dialog box opens.

10. Specify the settings for the checkpoint (select the specific checkbox which needs to be checked for e.g. for a link ‘innertext’ or ‘text’ checkbox should be selected).

11. Click on Modify button. Output Options dialog box opens.

12. Select Data Table in Output Types field.

13. Enter an appropriate name in the Name field.

14. Select Global Sheet radio button.

15. Click on OK button to close the Output Options dialog box.

16. Click on OK button to close the Output Value Properties dialog box. A checkpoint statement is added for the selected object.

This entry was posted in Quality Assurance & Testing and tagged , , , , , . Bookmark the permalink.

Leave a Reply