Qtp10 does not support flex plug-ins very well, and many advanced functions are faulty.
This is mainly because this plug-in is made by Adobe, and HP itself does not support flex. Adobe officially said that it will support qtp10 in the future. Since the company bought the license for qtp10, I can only try it out.
Installation and cracking steps:
1. Install qtp, which is basically the same as next. Do not crack the problem first.
2.beibeimgn-mqt90.exe to C:/program files/Mercury Interactive (create) folder
3. Create the C:/program files/common files/Mercury Interactive/License Manager folder
4.execute mgn-mqt90.exe
5. Open qtp10 and install the license file C:/program files/common files/Mercury Interactive/License Manager/lservrc #.
For example:
Expiration # "quicktestpro" version "6.0", no expiration date, exclusive
Feature # "FT-Unified" version "1.0", no expiration date, exclusive
Copy the token before # And then paste to the license entry in the license wizard.
6. then install the QTP Flex plug-in and find the installation directory of the flex builder. If you install it by default, you will find qtp_plugin_installer.exe in C:/Program Files/Adobe/Flex Builder 3/installers. Restart QTP and select flex3.0.0 and web to start recording the test script.
QTP settings
I have not studied it carefully because of too many configurations. You only need to remember that there are three basic settings.
File-> Settings
Tools-> Options
Tools-> View Options
Flex Builder settings
Add-include-libraries "c:/Program Files/Adobe/flex Builder 3/sdks/3.2.0/frameworks/libs/qtp to the Flex compiler command line. swc "" c:/Program Files/Adobe/Flex Builder 3/sdks/3.2.0/frameworks/libs/automation. swc "" c:/Program Files/Adobe/Flex Builder 3/sdks/3.2.0/frameworks/libs/automation_agent.swc "" c: /Program Files/Adobe/Flex Builder 3/sdks/3.2.0/frameworks/libs/automation_dmv.swc"
Recompile the entire project so that the flex application can use the QTP recording script.
Well, you can start recording the test script.
First, set the html wrapper of the flex application to be opened under web in automation-> Record and run settings, and then press Record in the toolbar to automatically open IE for recording. I recorded and modified a script as follows:
Browser ("Browser "). flexapplication ("Main "). flextextarea ("txtname "). selecttext 0, 0 <br/> browser ("Browser "). flexapplication ("Main "). flextextarea ("txtname "). input "aaaa" <br/> browser ("Browser "). flexapplication ("Main "). flextextarea ("txtname "). changefocus <br/> browser ("Browser "). flexapplication ("Main "). flextextarea ("txtpwd "). input "123456" <br/> browser ("Browser "). flexapplication ("Main "). flextextarea ("txtpwd "). type "enter" <br/> If browser ("Browser "). flexapplication ("Main "). flexalert ("warning "). exist (0) Then <br/> browser ("Browser "). flexapplication ("Main "). flexalert ("warning "). flexbutton ("yes "). type "enter" <br/> end if <br/> browser ("Browser "). flexapplication ("Main "). flexbutton ("logout "). click wait (2) <br/>
Then press play to test automatically.
After using it, I feel that QTP's support for Flex is still to be developed. The recorded script is basically useless without being modified. However, it only supports IE recording. In QTP10, Object spy is not applicable to Flex applications. Therefore, I decided to use RIATest to test the Flex application. For more information, see my blog.