Three qtp recording methods

Source: Internet
Author: User

Qtp has three modes:

1. Normal recording: identifies the objects of the tested software to operate the tested software. This is the most commonly used method, because this mode can make the automated code more readable, and the code maintainability is also good, the most important thing is portability, because the object will not change once the software under test is determined. The Code maintenance intensity is basically similar to the development and modification code intensity.

However, sometimes it is not possible to simply use this method. For example, the test case "you can drag and drop books on the bookshelf page" is not easy to use keyword. Next let's take a look at analog recording.

 

2. Analog recording: accurately records mouse movement and keyboard operations to operate the tested software. If you only need to record in the software under test, we choose relative and custom windows to record the operations outside the window. Otherwise, we choose relative and screen recording. Analog recording cannot be modified in qtp after recording steps. Because the recording result of analog recording is saved in a separate data file. We can only see a runanalog statement in the qtp code.

If you want to verify that a widget of the software is in a certain position. What should we do? Normal recording can only check whether this record exists, but cannot check the specific position of the control.

3. Low Level recording: recognizes all objects as windows or winobjects to operate the tested software. The operations are as follows:

Window test objects-click, dblclick, drag, drop, Type
Winobject test object-click, dblclick, drag, drop, type, activate, minimize, restore, maximize

Low level recording accurately records operations such as click coordinates, which is why low level recording can be used to verify a control at a certain position, however, do not use low level recording if it is not required for verification, because this recording method will make the automated code difficult to maintain, and it is difficult to adapt to any modifications to the software.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.