LoadRunner技巧之HTML与URL两种录制模式分析

发表于:2013-3-08 09:09

字体: | 上一篇 | 下一篇 | 我要投稿

 作者:虫师    来源:51Testing软件测试网采编

  URL方式的脚本:

Action()
{

    web_url(www.baidu.com,
        "URL=http://www.baidu.com/",
        "Resource=0",
        "RecContentType=text/html",
        "Referer=",
        "Snapshot=t67.inf",
        "Mode=HTTP",
        LAST);

    web_concurrent_start(NULL);

    web_url("shouye_b5486898c692066bd2cbaeda86d74448.gif",
        "URL=http://www.baidu.com/img/shouye_b5486898c692066bd2cbaeda86d74448.gif",
        "Resource=1",
        "RecContentType=image/gif",
        "Referer=http://www.baidu.com/",
        "Snapshot=t68.inf",
        LAST);

    web_url("gs.gif",
        "URL=http://www.baidu.com/cache/global/img/gs.gif",
        "Resource=1",
        "RecContentType=image/gif",
        "Referer=http://www.baidu.com/",
        "Snapshot=t69.inf",
        LAST);

    web_url("tangram-1.3.4c1.0.js",
        "URL=http://s1.bdstatic.com/r/www/cache/global/js/tangram-1.3.4c1.0.js",
        "Resource=1",
        "RecContentType=application/javascript",
        "Referer=http://www.baidu.com/",
        "Snapshot=t71.inf",
        LAST);

    web_url("home-2.5.js",
        "URL=http://s1.bdstatic.com/r/www/cache/global/js/home-2.5.js",
        "Resource=1",
        "RecContentType=application/javascript",
        "Referer=http://www.baidu.com/",
        "Snapshot=t72.inf",
        LAST);

    web_url("u-1.3.4.js",
        "URL=http://s1.bdstatic.com/r/www/cache/user/js/u-1.3.4.js",
        "Resource=1",
        "RecContentType=application/javascript",
        "Referer=http://www.baidu.com/",
        "Snapshot=t73.inf",
        LAST);

    web_concurrent_end(NULL);

    web_url("i-1.0.0.png",
        "URL=http://s1.bdstatic.com/r/www/img/i-1.0.0.png",
        "Resource=1",
        "RecContentType=image/png",
        "Referer=http://www.baidu.com/",
        "Snapshot=t70.inf",
        LAST);

    web_concurrent_start(NULL);

    web_url("su",
        "URL=http://suggestion.baidu.com/su?wd=&cb=window.bdsug.sugPreRequest&sid=1431_2031_1944_1788&t=1362056977341",
        "Resource=1",
        "RecContentType=baiduapp/json",
        "Referer=http://www.baidu.com/",
        "Snapshot=t74.inf",
        LAST);

    web_url("favicon.ico",
        "URL=http://www.baidu.com/favicon.ico",
        "Resource=1",
        "RecContentType=image/x-icon",
        "Referer=",
        "Snapshot=t75.inf",
        LAST);

    web_concurrent_end(NULL);

    return 0;
}

32/3<123>
《2023软件测试行业现状调查报告》独家发布~

精彩评论

  • xyshuang
    2013-9-02 08:49:56

    标题中的 html 拼错了

关注51Testing

联系我们

快捷面板 站点地图 联系我们 广告服务 关于我们 站长统计 发展历程

法律顾问:上海兰迪律师事务所 项棋律师
版权所有 上海博为峰软件技术股份有限公司 Copyright©51testing.com 2003-2024
投诉及意见反馈:webmaster@51testing.com; 业务联系:service@51testing.com 021-64471599-8017

沪ICP备05003035号

沪公网安备 31010102002173号