|
一:操作步骤:1、录制的步骤--webTours的登录、登出2、对sessionid进行关联
3、回放
问题:
报错信息,是给web_url匹配配置的参数失败才挂的么……
但web_url里的内容,他的请求和返回信息中并没有那串session值。为什么软件会对这里进行匹配呢
二:脚本如下
Action()
{
//Correlation comment - Do not change!Original value='48643175' Name ='CorrelationParameter_1'
web_set_max_html_param_len("1024000");
web_reg_save_param_ex(
"ParamName=CorrelationParameter_1",
"LB=125694.7",
"RB=z",
SEARCH_FILTERS,
"Scope=Body",
"RequestUrl=*/nav.pl*",
LAST);
//Correlation comment - Do not change!Original value='zDDDDDDD' Name ='CorrelationParameter_2'
web_reg_save_param_ex(
"ParamName=CorrelationParameter_2",
"LB=p",
"RB=D",
SEARCH_FILTERS,
"Scope=Body",
"RequestUrl=*/nav.pl*",
LAST);
web_url("webTours",
"URL=http://192.168.159.129:1080/webTours/",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTML",
EXTRARES,
"URL=http://www.bing.com/favicon.ico", ENDITEM,
LAST);
lr_think_time(7);
web_submit_data("login.pl",
"Action=http://192.168.159.129:1080/webTours/login.pl",
"Method=POST",
"RecContentType=text/html",
"Referer=http://192.168.159.129:1080/webTours/nav.pl?in=home",
"Snapshot=t2.inf",
"Mode=HTML",
ITEMDATA,
"Name=userSession", "Value=125694.7{CorrelationParameter_1}ztzftcDp{CorrelationParameter_2}DiHQcpftVi", ENDITEM,
"Name=username", "Value=jojo", ENDITEM,
"Name=password", "Value=bean", ENDITEM,
"Name=JSFormSubmit", "Value=on", ENDITEM,
"Name=login.x", "Value=20", ENDITEM,
"Name=login.y", "Value=10", ENDITEM,
LAST);
web_image("SignOff Button",
"Alt=SignOff Button",
"Snapshot=t3.inf",
LAST);
return 0;
}
三:报错信息
Action.c(26): 错误 -35061: 找不到请求的参数“CorrelationParameter_1”的匹配项。检查请求的边界是否存在于响应数据中。此外,如果要保存的数据超过 1024000 个字节,请使用 web_set_max_html_param_len 增加参数大小 [MsgId: MERR-35061]
Action.c(26): web_url("webTours") 最高严重级别为“ERROR”,6877 个正文字节,1808 个标头字节 [MsgId: MMSG-26388]
正在结束操作 Action。
|
|