测试的系统,录入身份证,生日就自动关联了身份证里的日期,是不是这个问题,使回放提交不了正确数据,所以不成功呢?
应该要怎么做才可以成功使用参数列表回放呢? 兄弟你这个问题我也遇见过我对一些数据都做了参数化 可是就是不好用后来我明白了有时候系统开发的时候会设置一些特殊字段而录制的时候也录制下来了 但我们没注意比如用户ID这类东西所以建议你试试是不是有某个数据还需要共同的参数化 你参数化得数据不全检查一下 看看是否好用 web_reg_save_param("Siebel_Analytic_ViewState5",
"LB/IC=ViewState\" value=\"",
"RB/IC=\"",
"Ord=1",
"Search=Body",
"RelFrameId=1",
LAST);
你在这里建立了关联..然后用web_url去GET你想要得到参数的那个页面。 嗯,,谢谢各位大哥的引导先,!!
不懂之处还要各位前辈的指导!
[ 本帖最后由 jaxcon 于 2009-6-8 12:18 编辑 ]
请问这是报什么错?
Action.c(60): Resource "http://192.168.0.19:801/web/Scripts/ga.js" is in the cache already and will not be downloaded againAction.c(60): Error -26377: No match found for the requested parameter "Siebel_Analytic_ViewState4". Check whether the requested boundaries exist in the response data. Also, if the data you want to save exceeds 3168 bytes, use web_set_max_html_param_len to increase the parameter size
Action.c(60): web_link("录入资料") highest severity level was "ERROR", 34991 body bytes, 1525 header bytes 如果脚本回放没有新记录生成,肯定是脚本回放有报错。尽管有些脚本错误只出现vuer_init
,action却可以顺利通过,那也没有用,因为init都没成功。
回复 32# 的帖子
我全部脚本都在action里的哟,参数化后回放报红色字错# 尝试把web_set_max_html_param_len()设置的大一些回复 34# 的帖子
试过效果一样, 学习中。。。。。 原帖由 Eric2515 于 2009-6-3 10:36 发表 http://bbs.51testing.com/images/common/back.gifweb_reg_save_param("Siebel_Analytic_ViewState5",
"LB/IC=ViewState\" value=\"",
"RB/IC=\"",
"Ord=1",
"Search=Body",
...
从错误提示来看,上面的见意是没错,应从这里下手找原因 嗯,不过本人的脚修改能力有限,学习脚本关联修改中,
另外我使用了自动关联,发现我们这个系统真是神,居然发现要N多的关联,被吓一跳,各位请查看一下!
web_reg_save_param("CSRule_1_UID5",
"LB= value=\"",
"RB=\"",
"Ord=5",
"Search=Body",
"RelFrameId=1",
LAST);
web_url("ItemLogin.aspx",
"URL=http://192.168.0.19:801/web/Training/ItemLogin.aspx",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTML",
EXTRARES,
"Url=../Picture/Imgs/login_bg.gif", ENDITEM,
"Url=../Picture/ModalDialogAlert.gif", ENDITEM,
"Url=/WebResource.axd?d=pQU6MJPbodMbEKQ1LuEnQe-KN8qpbleUoXCKbxBOxPRCiRxsHOph7cP7ScPQhlrMpyhVzyeRGTL8J4TwZWUo1Xu1EnDMzwRw1ktW9FBGp7A1&t=633718639428503750", ENDITEM,
"Url=http://www.google-analytics.com/__utm.gif?utmwv=4.3&utmn=239420248&utmhn=192.168.0.19&utmcs=utf-8&utmsr=1280x1024&utmsc=32-bit&utmul=zh-cn&utmje=1&utmfl=10.0%20r22&utmdt=%E5%B9%B3%E5%AE%89%E5%8D%A1%E7%BD%91%E4%B8%8A%E6%8A%A5%E5%90%8D&utmhid=492705696&utmr=-&utmp=/web/Training/ItemLogin.aspx&utmac=UA-6771362-2&utmcc=__utma%3D148375159.2369720308651925500.1243224185.1244602081.1244603015.80%3B%2B__utmz%3D148375159.1243224185.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D(none)%3B", ENDITEM,
"Url=/WebResource.axd?d=pQU6MJPbodMbEKQ1LuEnQe-KN8qpbleUoXCKbxBOxPR6jDv5pcG_K_M5H2dGkD9iY2uHAo15PM7mzrppbvhBFHMSvLjW094tivQ4Cm6TZB81&t=633718639428503750", ENDITEM,
LAST);
web_submit_form("ItemLogin.aspx_2",
"Snapshot=t2.inf",
ITEMDATA,
"Name=txtUS_Name", "Value=jaxcon", ENDITEM,
"Name=txtPass_Word", "Value=123", ENDITEM,
"Name=btnLogin", "Value={CSRule_1_UID5}", ENDITEM,
EXTRARES,
"Url=../Picture/Imgs/top_bg0.gif", "Referer=http://192.168.0.19:801/web/Training/ItemIndex.aspx", ENDITEM,
"Url=http://www.google-analytics.com/__utm.gif?utmwv=4.3&utmn=702716767&utmhn=192.168.0.19&utmcs=utf-8&utmsr=1280x1024&utmsc=32-bit&utmul=zh-cn&utmje=1&utmfl=10.0%20r22&utmdt=%E5%B9%B3%E5%AE%89%E5%8D%A1%E7%BD%91%E4%B8%8A%E6%8A%A5%E5%90%8D%E7%B3%BB%E7%BB%9F&utmhid=873620568&utmr=0&utmp=/web/Training/ItemIndex.aspx&utmac=UA-6771362-2&utmcc=__utma%3D148375159.2369720308651925500.1243224185.1244602081.1244603015.80%3B%2B__utmz%3D148375159.1243224185.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D"
"(none)%3B", "Referer=http://192.168.0.19:801/web/Training/ItemIndex.aspx", ENDITEM,
"Url=http://www.google-analytics.com/__utm.gif?utmwv=4.3&utmn=154699563&utmhn=192.168.0.19&utmcs=utf-8&utmsr=1280x1024&utmsc=32-bit&utmul=zh-cn&utmje=1&utmfl=10.0%20r22&utmhid=1233056540&utmr=0&utmp=/web/Training/ItemMain.aspx&utmac=UA-6771362-2&utmcc=__utma%3D148375159.2369720308651925500.1243224185.1244602081.1244603015.80%3B%2B__utmz%3D148375159.1243224185.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D(none)%3B", "Referer=http://192.168.0.19:801/web/Training/ItemMain.aspx", ENDITEM,
LAST);
web_add_cookie("__utmb=148375159.3.10.1244603015; DOMAIN=192.168.0.19");
/* Registering parameter(s) from source task id 52
// {CSRule_1_UID21} = "/wEPDwUINjA2ODcyMDQPZBYCAgMPFgIeB2VuY3R5cGUFE211bHRpcGFydC9mb3JtLWRhdGEWDgIBDw8WAh4XRW5hYmxlQWpheFNraW5SZW5kZXJpbmdoZGQCAg8PFgQeDFJlbG9hZE9uU2hvd2cfAWhkZAIED2QWBAIBDxYCHglpbm5lcmh0bWwFHuS6uuWRmOaho+ahiOS/oeaBr+W9leWFpemhtemdomQCAw8WAh8DBQYmbmJzcDtkAgYPZBYCZg9kFgICAQ8PFgIeCFJlYWRPbmx5aGRkAhIPZBYEAgEPFgIfAwVNW+Wkqeays+S9k+iCsuS4nOW3peeoi+WFrOWPuDAwNDRfMjAwOTA2MDVfTjA4NTg1MF3mibnmrKHkurrlkZjliJfooaggWyAw5Lq6IF1kAgMPFgIfAwUGJm5ic3A7ZAIaDzwrAAsBAA8WCB4IRGF0YUtleXMWAB4LXyFJdGVtQ291bnRmHglQYWdlQ291bnQCAR4VXyFEYXRhU291cmNlSXRlbUNvdW50ZmRkAhsPDxYCHgdFbmFibGVkaGRkGAEFHl9fQ29udHJvbHNSZXF1aXJlUG9zdEJhY2tLZXlfXxYCBRFSYWRGb3JtRGVjb3JhdG9yMQUUTWFpblJhZFdpbmRvd01hbmFnZXI="
// */
web_reg_save_param("CSRule_1_UID21",
"LB= value=\"",
"RB=\"",
"Ord=3",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 52
// {CSRule_1_UID29} = "/wEWDALgnrjRCwKBrNSSAgLt252FDQKuk6fDCgKF9IT6BQLEhISFCwKOsfKTCQLvjry/BQLt3oXMAwLCi9reAwL+6YyoCgKK+sjUBw=="
// */
web_reg_save_param("CSRule_1_UID29",
"LB= value=\"",
"RB=\"",
"Ord=13",
"Search=Body",
"RelFrameId=1",
LAST);
web_link("录入资料",
"Text=录入资料",
"Snapshot=t3.inf",
EXTRARES,
"Url=../Picture/Imgs/pici_top.gif", "Referer=http://192.168.0.19:801/web/Training/InsertItemTrain.aspx?course_id=15488&isSeriesNo=false", ENDITEM,
"Url=../picture/DataGrid.htc", "Referer=", ENDITEM,
"Url=http://www.google-analytics.com/__utm.gif?utmwv=4.3&utmn=1875815025&utmhn=192.168.0.19&utmcs=utf-8&utmsr=1280x1024&utmsc=32-bit&utmul=zh-cn&utmje=1&utmfl=10.0%20r22&utmdt=%E6%97%A0%E6%A0%87%E9%A2%98%E9%A1%B5&utmhid=756772309&utmr=0&utmp=/web/Training/InsertItemTrain.aspx?course_id=15488&isSeriesNo=false&utmac=UA-6771362-2&utmcc=__utma%3D148375159.2369720308651925500.1243224185.1244602081.1244603015.80%3B%2B__utmz%3D148375159.1243224185.1.1.utmcsr%3D(direct)%7Cutmccn%3D(direct)%7Cutmcmd%3D(none"
")%3B", "Referer=http://192.168.0.19:801/web/Training/InsertItemTrain.aspx?course_id=15488&isSeriesNo=false", ENDITEM,
LAST);
web_add_cookie("__utmb=148375159.4.10.1244603015; DOMAIN=192.168.0.19");
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID48} = "4"
// */
web_reg_save_param("CSRule_1_UID48",
"LB= value=\"",
"RB=\"",
"Ord=9",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID47} = "3"
// */
web_reg_save_param("CSRule_1_UID47",
"LB= value=\"",
"RB=\"",
"Ord=8",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID45} = "1"
// */
web_reg_save_param("CSRule_1_UID45",
"LB= value=\"",
"RB=\"",
"Ord=6",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID85} = "18"
// */
web_reg_save_param("CSRule_1_UID85",
"LB= value=\"",
"RB=\"",
"Ord=54",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID51} = "7"
// */
web_reg_save_param("CSRule_1_UID51",
"LB= value=\"",
"RB=\"",
"Ord=12",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID49} = "5"
// */
web_reg_save_param("CSRule_1_UID49",
"LB= value=\"",
"RB=\"",
"Ord=10",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID52} = "8"
// */
web_reg_save_param("CSRule_1_UID52",
"LB= value=\"",
"RB=\"",
"Ord=13",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID79} = "38"
// */
web_reg_save_param("CSRule_1_UID79",
"LB= value=\"",
"RB=\"",
"Ord=48",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID97} = "50"
// */
web_reg_save_param("CSRule_1_UID97",
"LB= value=\"",
"RB=\"",
"Ord=68",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID88} = "19"
// */
web_reg_save_param("CSRule_1_UID88",
"LB= value=\"",
"RB=\"",
"Ord=57",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID46} = "2"
// */
web_reg_save_param("CSRule_1_UID46",
"LB= value=\"",
"RB=\"",
"Ord=7",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID73} = "16"
// */
web_reg_save_param("CSRule_1_UID73",
"LB= value=\"",
"RB=\"",
"Ord=42",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID54} = "0"
// */
web_reg_save_param("CSRule_1_UID54",
"LB= value=\"",
"RB=\"",
"Ord=15",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID53} = "9"
// */
web_reg_save_param("CSRule_1_UID53",
"LB= value=\"",
"RB=\"",
"Ord=14",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID66} = "12"
// */
web_reg_save_param("CSRule_1_UID66",
"LB= value=\"",
"RB=\"",
"Ord=34",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID61} = "24"
// */
web_reg_save_param("CSRule_1_UID61",
"LB= value=\"",
"RB=\"",
"Ord=29",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID77} = "32"
// */
web_reg_save_param("CSRule_1_UID77",
"LB= value=\"",
"RB=\"",
"Ord=46",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID84} = "10"
// */
web_reg_save_param("CSRule_1_UID84",
"LB= value=\"",
"RB=\"",
"Ord=53",
"Search=Body",
"RelFrameId=1",
LAST);
/* Registering parameter(s) from source task id 59
// {CSRule_1_UID94} = "20"
// */
下面还有一半,不够长度粘上来!
应该参数的取值方式设置的不对
参数列表看起来不起作用,应该是取值方式设置错误,取值方式可能是选择了Sequential和Once如果将来的场景中只是用一个用户跑脚本的话,脚本中的参数属性取值方式应该设置为Sequential和Each iteration
如果是多个用户跑脚本,并且每个用户取的值都不相同的话,脚本中的参数属性取值方式应该设置为Unique和Each iteration
回复 39# 的帖子
我试过用上面的几种取值方式都不行;现在我用自动联关录制脚本后,奇怪的是,不是每次都能成功回放参数化表,
录制时的行为动作是一样的,真是怪;
有时只要调大web_set_max_html_param_len("2456")里的值就可以正常回放参化表;
请大家交流经验; 试着看一下你的 COOKIES ,这个也需要关联.. 学习中..........
sdff
在脚本里插入下面代码,在回放log里可以看到每次的用户名取值lr_log_message("用户名:%s",lr_eval_string("{NewParam}");
页:
1
[2]