51Testing软件测试论坛

标题: 求助啊!web_submit_form执行错误 [打印本页]

作者: rubydove    时间: 2005-11-8 09:33
标题: 求助啊!web_submit_form执行错误
录像登陆的功能:
Action()
{

        web_url("192.168.7.166:8000",
                "URL=http://192.168.7.166:8000/",
                "Resource=0",
                "RecContentType=text/html",
                "Referer=",
                "Snapshot=t1.inf",
                "Mode=HTML",
                LAST);

        web_url("layout",
                "URL=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1",
                "Resource=0",
                "RecContentType=text/html",
                "Referer=",
                "Snapshot=t2.inf",
                "Mode=HTML",
                EXTRARES,
                "Url=/html/themes/classic/templates/body_bg.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/images/login/login_bg.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/color_schemes/01/portlet_title_bg_gradient.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/color_schemes/01/portlet_corner_ul.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/color_schemes/01/portlet_corner_ur.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/images/shadow/middle.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/images/shadow/left.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                "Url=/html/themes/classic/images/shadow/right.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=21.1", ENDITEM,
                LAST);

        lr_think_time(7);

        web_submit_form("login",
                "Snapshot=t3.inf",
                ITEMDATA,
                "Name=my_account_login", "Value=licy@gdtz.com.cn", ENDITEM,
                "Name=ommiitkiwn_my_account_password", "Value=1111", ENDITEM,
                "Name=my_account_r_m", "Value=<OFF>", ENDITEM,
                LAST);

        web_url("protected",
                "URL=http://192.168.7.166:8000/c/portal/protected",
                "Resource=0",
                "RecContentType=text/html",
                "Referer=",
                "Snapshot=t4.inf",
                "Mode=HTML",
                LAST);

        web_submit_form("j_security_check",
                "Snapshot=t5.inf",
                ITEMDATA,
                EXTRARES,
                "Url=/flash/Itsmoe_logo.swf", "Referer=", ENDITEM,
                "Url=/html/themes/classic/color_schemes/01/tab_middle_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/up_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/down_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/min_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/restore_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/restore_off.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/max_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/portlet/close_on.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/flash/analogclock.swf", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/images/UseInfo/yhxx.jpg", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                "Url=/html/themes/classic/color_schemes/01/portlet_menu_bg_gradient.gif", "Referer=http://192.168.7.166:8000/c/portal/layout?p_l_id=1", ENDITEM,
                LAST);

        return 0;
}

执行到web_submit_form(加粗的),执行跳出,错误信息:
Action.c(33): Error -27979: Requested form not found         [MsgId: MERR-27979]
Action.c(33): web_submit_form("login") highest severity level was "ERROR", 0 body bytes, 0 header bytes         [MsgId: MMSG-26388]
Ending action Action.
作者: rubydove    时间: 2005-11-8 10:39
找到问题的所在了,但是不知道怎么解决:

"Name=******_my_account_password", "Value=1111", ENDITEM,

每次登陆的时候,******都会随机产生,所以导致submit错误


请问这个问题怎么解决?????请高手指点
作者: bsd3000    时间: 2005-11-8 11:26
做自动或者手动关联
作者: rubydove    时间: 2005-11-8 17:10
Thanks!!!!!!!!!!!!!




欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/) Powered by Discuz! X3.2