插入文本检查点后运行报错找不到文本,请教
插入文本检查点后运行报错找不到文本,请教!Action.c(12): 错误 -26366: 找不到 web_reg_find 的“Text=开发建设项目水土保持方案管理”
Action.c(12): web_url("beijingsw") 最高严重级别为“ERROR”,70260 个正文字节,321 个标头字节 不加检查点就没有错,只要加检查点就报上面的错误。
现在我在测试并发,大家说我在事务前设置了thinktime后,在事务前还要加集合点吗!? 测试并发,要加集合点。
你的检查点加在什么位置?
把脚本贴出来瞧瞧哈 Action()
{
web_reg_find("Text=开发建设项目水土保持方案管理",
"Search=body",
LAST);
web_url("beijingsw",
"URL=http://dtgisserver/beijingsw/",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTTP",
LAST);
web_concurrent_start(NULL);
web_url("css.css",
"URL=http://dtgisserver/beijingsw/css.css",
"Resource=1",
"RecContentType=text/css",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t2.inf",
LAST);
web_url("maimenu.jpg",
"URL=http://dtgisserver/beijingsw/bjImg/maimenu.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t4.inf",
LAST);
web_url("coin_lanmu3.gif",
"URL=http://dtgisserver/beijingsw/bjImg/coin_lanmu3.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t6.inf",
LAST);
web_url("dian.gif",
"URL=http://dtgisserver/beijingsw/bjimg/dian.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t7.inf",
LAST);
web_url("line1.gif",
"URL=http://dtgisserver/beijingsw/Img/line1.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t8.inf",
LAST);
web_url("coin_lanmu4.gif",
"URL=http://dtgisserver/beijingsw/bjImg/coin_lanmu4.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t9.inf",
LAST);
web_url("btn_search.gif",
"URL=http://dtgisserver/beijingsw/bjImg/btn_search.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t10.inf",
LAST);
web_url("74.jpg",
"URL=http://dtgisserver/beijingsw/bjfengcaiImg/74.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t11.inf",
LAST);
web_url("xiao19.jpg",
"URL=http://dtgisserver/beijingsw/bjfengcaiImg/xiao19.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t12.inf",
LAST);
web_url("xiao8.jpg",
"URL=http://dtgisserver/beijingsw/bjfengcaiImg/xiao8.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t13.inf",
LAST);
web_url("bjfoot.gif",
"URL=http://dtgisserver/beijingsw/bjImg/bjfoot.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t14.inf",
LAST);
web_url("line_short2.gif",
"URL=http://dtgisserver/beijingsw/Img/line_short2.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t15.inf",
LAST);
web_url("xiao11.jpg",
"URL=http://dtgisserver/beijingsw/bjfengcaiImg/xiao11.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t16.inf",
LAST);
web_url("coin_lanmu.gif",
"URL=http://dtgisserver/beijingsw/bjImg/coin_lanmu.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t17.inf",
LAST);
web_url("xiao12.jpg",
"URL=http://dtgisserver/beijingsw/bjfengcaiImg/xiao12.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t18.inf",
LAST);
web_url("coin_lanmu5.gif",
"URL=http://dtgisserver/beijingsw/bjImg/coin_lanmu5.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t19.inf",
LAST);
web_url("coin_lanmu2.gif",
"URL=http://dtgisserver/beijingsw/bjImg/coin_lanmu2.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t21.inf",
LAST);
web_concurrent_end(NULL);
web_url("top.swf",
"URL=http://dtgisserver/beijingsw/bjImg/top.swf",
"Resource=1",
"RecContentType=application/x-shockwave-flash",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t3.inf",
LAST);
web_url("lanmu4.gif",
"URL=http://dtgisserver/beijingsw/bjImg/lanmu4.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t5.inf",
LAST);
web_url("lanmu5.gif",
"URL=http://dtgisserver/beijingsw/bjImg/lanmu5.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t20.inf",
LAST);
lr_think_time(30);
lr_start_transaction("1法规标准");
web_reg_find("Text=水保法规",
"Search=body",
LAST);
web_url("?",
"URL=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Resource=0",
"RecContentType=text/html",
"Referer=http://dtgisserver/beijingsw/",
"Snapshot=t22.inf",
"Mode=HTTP",
LAST);
web_concurrent_start(NULL);
web_url("tcss.css",
"URL=http://dtgisserver/beijingsw/tcss.css",
"Resource=1",
"RecContentType=text/css",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t23.inf",
LAST);
web_url("arrow.gif",
"URL=http://dtgisserver/beijingsw/img/arrow.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t24.inf",
LAST);
web_url("line_long.gif",
"URL=http://dtgisserver/beijingsw/Img/line_long.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t26.inf",
LAST);
web_url("left-3.gif",
"URL=http://dtgisserver/beijingsw/bjImg/left-3.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t27.inf",
LAST);
web_url("fjbz.gif",
"URL=http://dtgisserver/beijingsw/bjImg/button/FirstLan/fjbz.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t28.inf",
LAST);
web_url("left-2.gif",
"URL=http://dtgisserver/beijingsw/bjImg/left-2.gif",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t29.inf",
LAST);
web_url("left-1.GIF",
"URL=http://dtgisserver/beijingsw/bjImg/left-1.GIF",
"Resource=1",
"RecContentType=image/gif",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t30.inf",
LAST);
web_url("css.css_2",
"URL=http://dtgisserver/beijingsw/css.css",
"Resource=1",
"Referer=http://dtgisserver/beijingsw/Public/flfgxx.aspx?id=78",
LAST);
web_url("maimenu.jpg_2",
"URL=http://dtgisserver/beijingsw/bjImg/maimenu.jpg",
"Resource=1",
"Referer=http://dtgisserver/beijingsw/Public/flfgxx.aspx?id=78",
LAST);
web_url("bjfoot.gif_2",
"URL=http://dtgisserver/beijingsw/bjImg/bjfoot.gif",
"Resource=1",
"Referer=http://dtgisserver/beijingsw/Public/flfgxx.aspx?id=78",
LAST);
web_concurrent_end(NULL);
web_url("lanmu.jpg",
"URL=http://dtgisserver/beijingsw/bjImg/lanmu.jpg",
"Resource=1",
"RecContentType=image/jpeg",
"Referer=http://dtgisserver/beijingsw/Public/zcfg.aspx",
"Snapshot=t25.inf",
LAST);
lr_end_transaction("1法规标准", LR_AUTO);
lr_think_time(30); lr的文本检查对于中文内容支持一项不好,我曾经试过web_reg_find("text=成功");
结果查找失败,但我把里面的成功换成success就可以了,很郁闷的! 用web_find呢? 刚才搜索了一下web_find和web_reg_find的区别
http://bbs.51testing.com/viewthread.php?tid=101968 我刚刚也试了一下,用web_reg_find() 找中文检查点,failed
后来,换了web_find(),就ok了
看你的脚本貌似没什么问题,你换个web_find()试试
看贴的高手们呢,发表发表意见啊...... 路过
还没有真实实践过。等有机会实践了好占座 录制基于HTML的脚本时,使用web_find
录制基于url的脚本时,web_reg_find
你是在录制完脚本回放时提示出错
还是在运行场景测试的时候提示出错呢 楼主,你的问题解决了么 ? 我现在也是同样的情况,总是找不到设置检查点 哪位大神能告诉我插入检查点后,检查的内容都找到了,但是我下面写的if else判断为什么老走else语句,这是代码
web_reg_find("Search=Body",
"SaveCount=varchar_count",
"Text=VARCHAR2",
LAST);
if(atoi(lr_eval_string("{varchar_count}"))>0)
lr_output_message("Log on successful");
else
lr_output_message("Log on fali");
然后reply log中有这样的警告Warning: The string 'varchar_count' with parameter delimiters is not a parameter. 大哥,检查的报文 不要用中文。。。web_reg_find("Search=这里不要用中文 哪位大神知道给回一个呗 楼主的问题解决了吗,我现在遇到同样的问题 lgy0922 发表于 2008-5-8 14:04
Action()
{
其实人家loadrunner他老人家只认乱码的中文,不认正规的汉字
页:
[1]