|
4#
楼主 |
发表于 2011-3-4 10:46:00
|
只看该作者
我录制的lr教程中的实例 ,若是在回放的时候不选择:show browser during replay 就不会出现这个弹出框了,我录制的其他的网页的脚本回放的时候,即使选择了这项也不会出现这样的弹出框
但是为啥lr教程中的实例中 选择这项的时候不行呢 我记得以前选择这项没有出现过这样的问题
以下是录制的脚本:
Action()
{
web_url("mercuryWebTours",
"URL=http://127.0.0.1:1080/mercuryWebTours/",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t9.inf",
"Mode=HTML",
LAST);
lr_think_time(14);
web_submit_form("login.pl",
"Snapshot=t10.inf",
ITEMDATA,
"Name=username", "Value=jojo", ENDITEM,
"Name=password", "Value=bean", ENDITEM,
"Name=login.x", "Value=37", ENDITEM,
"Name=login.y", "Value=10", ENDITEM,
LAST);
lr_rendezvous("flight");
lr_start_transaction("flights");
lr_think_time(24);
web_image("Search Flights Button",
"Alt=Search Flights Button",
"Snapshot=t11.inf",
LAST);
lr_think_time(5);
web_url("FormDateUpdate.class",
"URL=http://127.0.0.1:1080/mercuryWebTours/FormDateUpdate.class",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Mode=HTML",
LAST);
web_url("CalSelect.class",
"URL=http://127.0.0.1:1080/mercuryWebTours/CalSelect.class",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Mode=HTML",
LAST);
web_submit_data("reservations.pl",
"Action=http://127.0.0.1:1080/mercuryWebTours/reservations.pl",
"Method=POST",
"RecContentType=text/html",
"Referer=http://127.0.0.1:1080/mercuryWebTours/reservations.pl?page=welcome",
"Snapshot=t12.inf",
"Mode=HTML",
ITEMDATA,
"Name=advanceDiscount", "Value=0", ENDITEM,
"Name=depart", "Value=Denver", ENDITEM,
"Name=departDate", "Value=03/03/2011", ENDITEM,
"Name=arrive", "Value=Denver", ENDITEM,
"Name=returnDate", "Value=03/04/2011", ENDITEM,
"Name=numPassengers", "Value=1", ENDITEM,
"Name=seatPref", "Value={seat}", ENDITEM,
"Name=seatType", "Value=Coach", ENDITEM,
"Name=.cgifields", "Value=roundtrip", ENDITEM,
"Name=.cgifields", "Value=seatType", ENDITEM,
"Name=.cgifields", "Value=seatPref", ENDITEM,
"Name=findFlights.x", "Value=28", ENDITEM,
"Name=findFlights.y", "Value=10", ENDITEM,
LAST);
web_url("Calendar.class",
"URL=http://127.0.0.1:1080/mercuryWebTours/Calendar.class",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Mode=HTML",
LAST);
web_submit_data("reservations.pl_2",
"Action=http://127.0.0.1:1080/mercuryWebTours/reservations.pl",
"Method=POST",
"RecContentType=text/html",
"Referer=http://127.0.0.1:1080/mercuryWebTours/reservations.pl",
"Snapshot=t13.inf",
"Mode=HTML",
ITEMDATA,
"Name=outboundFlight", "Value=000;0;03/03/2011", ENDITEM,
"Name=numPassengers", "Value=1", ENDITEM,
"Name=advanceDiscount", "Value=0", ENDITEM,
"Name=seatType", "Value=Coach", ENDITEM,
"Name=seatPref", "Value=Aisle", ENDITEM,
"Name=reserveFlights.x", "Value=44", ENDITEM,
"Name=reserveFlights.y", "Value=13", ENDITEM,
LAST);
web_submit_form("reservations.pl_3",
"Snapshot=t14.inf",
ITEMDATA,
"Name=firstName", "Value=Joseph", ENDITEM,
"Name=lastName", "Value=Marshall", ENDITEM,
"Name=address1", "Value=234 Willow Drive", ENDITEM,
"Name=address2", "Value=San Jose/CA/94085", ENDITEM,
"Name=pass1", "Value=Joseph Marshall", ENDITEM,
"Name=creditCard", "Value=", ENDITEM,
"Name=expDate", "Value=", ENDITEM,
"Name=saveCC", "Value=<OFF>", ENDITEM,
"Name=buyFlights.x", "Value=43", ENDITEM,
"Name=buyFlights.y", "Value=5", ENDITEM,
LAST);
lr_end_transaction("flights",LR_AUTO);
return 0;
} |
|