|
我刚才又做了一遍,脚本是这样的.文本检查还是那个错误
Action()
{
web_url("MercuryWebTours",
"URL=http://localhost:1080/MercuryWebTours",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTML",
LAST);
lr_think_time(7);
web_submit_form("login.pl",
"Snapshot=t2.inf",
ITEMDATA,
"Name=username", "Value=jojo", ENDITEM,
"Name=password", "Value=bean", ENDITEM,
"Name=login.x", "Value=34", ENDITEM,
"Name=login.y", "Value=8", ENDITEM,
LAST);
lr_start_transaction("NewTransaction");
web_image("Search Flights Button",
"Alt=Search Flights Button",
"Snapshot=t3.inf",
LAST);
lr_think_time(5);
web_submit_form("reservations.pl",
"Snapshot=t4.inf",
ITEMDATA,
"Name=depart", "Value=Denver", ENDITEM,
"Name=departDate", "Value=03/28/2007", ENDITEM,
"Name=arrive", "Value=Los Angeles", ENDITEM,
"Name=returnDate", "Value=03/29/2007", ENDITEM,
"Name=numPassengers", "Value=1", ENDITEM,
"Name=roundtrip", "Value=<OFF>", ENDITEM,
"Name=seatPref", "Value=Aisle", ENDITEM,
"Name=seatType", "Value=Coach", ENDITEM,
"Name=findFlights.x", "Value=28", ENDITEM,
"Name=findFlights.y", "Value=10", ENDITEM,
LAST);
web_submit_form("reservations.pl_2",
"Snapshot=t5.inf",
ITEMDATA,
"Name=outboundFlight", "Value=030;251;03/28/2007", ENDITEM,
"Name=reserveFlights.x", "Value=24", ENDITEM,
"Name=reserveFlights.y", "Value=9", ENDITEM,
LAST);
lr_end_transaction("NewTransaction", LR_AUTO);
lr_think_time(8);
web_submit_form("reservations.pl_3",
"Snapshot=t6.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=12345678", ENDITEM,
"Name=expDate", "Value=06/06", ENDITEM,
"Name=saveCC", "Value=<OFF>", ENDITEM,
"Name=buyFlights.x", "Value=64", ENDITEM,
"Name=buyFlights.y", "Value=7", ENDITEM,
LAST);
web_image("Itinerary Button",
"Alt=Itinerary Button",
"Snapshot=t7.inf",
LAST);
lr_think_time(12);
web_image("SignOff Button",
"Alt=SignOff Button",
"Snapshot=t8.inf",
LAST);
return 0;
} |
|