|
QTP的实例:第一次回放脚本的时候,完全正常
Welcome: Mercury Tours").Page("Welcome: Mercury Tours").WebEdit("userName").Set "mickey_ice"
Browser("Welcome: Mercury Tours").Page("Welcome: Mercury Tours").WebEdit("password").SetSecure "44e50edc422cf31fc4f30229"
Browser("Welcome: Mercury Tours").Page("Welcome: Mercury Tours").WebEdit("password").SetSecure "44e50ede34c0956741dfa50acc2cda4768403332"
Browser("Welcome: Mercury Tours").Page("Welcome: Mercury Tours").Image("Sign-In").Click 2,2
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebList("fromMonth").Select "December"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebList("fromDay").Select "22"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebList("toPort").Select "San Francisco"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebList("toMonth").Select "December"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebList("toDay").Select "29"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").WebRadioGroup("servClass").Select "Business"
Browser("Welcome: Mercury Tours").Page("Find a Flight: Mercury").Image("findFlights").Click 75,11
Browser("Welcome: Mercury Tours").Page("Select a Flight: Mercury").Image("reserveFlights").Click 72,3
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").WebEdit("passFirst0").Set "catherine"
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").WebEdit("passLast0").Set "li"
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").WebEdit("passLast0").Check CheckPoint("passLast0")
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").WebEdit("creditnumber").Set "88888888"
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").WebCheckBox("ticketLess").Set "ON"
Browser("Welcome: Mercury Tours").Page("Book a Flight: Mercury").Image("buyFlights").Click 43,3
Browser("Welcome: Mercury Tours").Page("Select a Flight: Mercury").Check CheckPoint("Select a Flight: Mercury_3")
Browser("Welcome: Mercury Tours").Page("Flight Confirmation: Mercury").Image("home").Click
第二次回放的时候:在登录那一块出现错误-》错误的详细信息:Object Details Result Time Sign-In The statement contains one or more invalid function arguments. Failed 2006-8-19 - 14
在网络低峰的时候不会出现这个问题。我想知道在高峰时我们应该如何避免出现类似问题
是不是可以加个”wait(5)“具体怎么做呢 |
|