|
测试环境:windows XP
测试工具:LR9.1 HTTP/HTML协议
被测试系统:OA系统、基于B/S构架的,前台用Javascript开发,后台是Weblogic+Oracle
录制过程描述: 打开功能设置页面,点击某功能模块,新建一个机构,输入机构编号和名称,提交完毕!
代码说明: 以下是部分的代码段,直接录制后回放将报错,需要设置关联。"Name=javax.faces.ViewState", "Value={WCSParam_Diff3}" 这部分就是关联的值,可能是每次服务器都要发送一个不同的值。
问题:录制完毕脚本后,无法在脚本中找到关于输入机构编号和名称的参数, 在以下代码中web_submit_data函数段并没有输入的参数。录制中我尝试用HTML或URL模式,均找到不到输入机构编号和名称的参数。
// [WCSPARAM WCSParam_Diff1 20 j_id_id1:j_id_id3pc2] Parameter {WCSParam_Diff1} created by Correlation Studio
web_reg_save_param("WCSParam_Diff1",
"LB= value=\"",
"RB=\"",
"Ord=1",
"RelFrameId=1",
"Search=Body",
"IgnoreRedirections=Yes",
LAST);
// [WCSPARAM WCSParam_Diff2 10 !-2834c41d] Parameter {WCSParam_Diff2} created by Correlation Studio
web_reg_save_param("WCSParam_Diff2",
"LB= value=\"",
"RB=\"",
"Ord=2",
"RelFrameId=1",
"Search=Body",
"IgnoreRedirections=Yes",
LAST);
// [WCSPARAM WCSParam_Diff5 4 j_id] Parameter {WCSParam_Diff5} created by Correlation Studio
web_reg_save_param("WCSParam_Diff5",
"LB=div id=\"",
"RB=_id1",
"Ord=1",
"RelFrameId=1",
"Search=Body",
"IgnoreRedirections=Yes",
LAST);
web_submit_data("main.jspx_2", "Action=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}",
"Method=POST",
"EncType=multipart/form-data",
"RecContentType=text/html",
"Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}",
"Snapshot=t2.inf",
"Mode=HTML",
ITEMDATA,
"Name=org.apache.myfaces.trinidad.faces.FORM", "Value=pageTemplate:j_id_id3pc2", ENDITEM,
"Name=javax.faces.ViewState", "Value={WCSParam_Diff3}", ENDITEM,
"Name=event", "Value=pageTemplate:j_id_id68pc2", ENDITEM,
"Name=event.pageTemplate:j_id_id68pc2", "Value=<m xmlns=\"http://oracle.com/richClient/comm\"><k v=\"type\"><s>action</s></k></m>", ENDITEM,
EXTRARES,
"URL=../afr/ccont_header_start.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/ccont_header_bg.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/toolbar_sSeparator.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/th_bg_s.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/ccont_header_end.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/column-select.cur", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../resources/imgs/paneltab_border.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/overflow_start.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/overflow_end.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../resources/imgs/paneltab_center_selected.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/sort_des_n.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../afr/sort_asc_n.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../resources/imgs/paneltab_right_selected.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
"URL=../resources/imgs/paneltab_left_selected.png", "Referer=http://192.168.1.90:7001/matrix/faces/main.jspx?_adf.ctrl-state={WCSParam_Diff4}", ENDITEM,
LAST);问题
[ 本帖最后由 wensy 于 2009-7-24 18:57 编辑 ] |
|