51Testing软件测试论坛

 找回密码
 (注-册)加入51Testing

QQ登录

只需一步,快速开始

微信登录,快人一步

手机号码,快捷登录

查看: 5036|回复: 3
打印 上一主题 下一主题

[原创] loadrunner怎么设置日志才只能显示输出结果?

[复制链接]
  • TA的每日心情
    奋斗
    2018-6-19 15:14
  • 签到天数: 27 天

    连续签到: 1 天

    [LV.4]测试营长

    跳转到指定楼层
    1#
    发表于 2011-4-22 10:48:17 | 只看该作者 回帖奖励 |正序浏览 |阅读模式
    现在回放脚本时,日志显示:
    添加了这个语句:lr_output_message("%s",lr_eval_string("{passengers}"));
    输出日志如下:
    Action.c(6): Found resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" in HTML "http://127.0.0.1:1080/WebTours/reservations.pl"          [MsgId: MMSG-26659]
    Action.c(6): web_submit_data("reservations.pl") was successful, 3065 body bytes, 417 header bytes          [MsgId: MMSG-26386]
    Action.c(29): Submitting form to "http://127.0.0.1:1080/WebTours/reservations.pl", Target Frame=""          [MsgId: MMSG-27978]
    Action.c(29): Resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(29): web_submit_form("reservations.pl_2") was successful, 8149 body bytes, 253 header bytes          [MsgId: MMSG-26386]
    Action.c(36): 64
    Ending action Action.
    Ending iteration 1.
    Starting iteration 2.
    Starting action Action.
    Action.c(6): Found resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" in HTML "http://127.0.0.1:1080/WebTours/reservations.pl"          [MsgId: MMSG-26659]
    Action.c(6): web_submit_data("reservations.pl") was successful, 3065 body bytes, 417 header bytes          [MsgId: MMSG-26386]
    Action.c(29): Submitting form to "http://127.0.0.1:1080/WebTours/reservations.pl", Target Frame=""          [MsgId: MMSG-27978]
    Action.c(29): Resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(29): web_submit_form("reservations.pl_2") was successful, 3184 body bytes, 253 header bytes          [MsgId: MMSG-26386]
    Action.c(36): 10Ending action Action.
    Ending iteration 2.
    Starting iteration 3.
    Starting action Action.
    Action.c(6): Found resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" in HTML "http://127.0.0.1:1080/WebTours/reservations.pl"          [MsgId: MMSG-26659]
    Action.c(6): web_submit_data("reservations.pl") was successful, 3065 body bytes, 417 header bytes          [MsgId: MMSG-26386]
    Action.c(29): Submitting form to "http://127.0.0.1:1080/WebTours/reservations.pl", Target Frame=""          [MsgId: MMSG-27978]
    Action.c(29): Resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(29): web_submit_form("reservations.pl_2") was successful, 3116 body bytes, 253 header bytes          [MsgId: MMSG-26386]
    Action.c(36): 12Ending action Action.
    Ending iteration 3.
    Starting iteration 4.
    Starting action Action.
    Action.c(6): Found resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" in HTML "http://127.0.0.1:1080/WebTours/reservations.pl"          [MsgId: MMSG-26659]
    Action.c(6): web_submit_data("reservations.pl") was successful, 3065 body bytes, 417 header bytes          [MsgId: MMSG-26386]
    Action.c(29): Submitting form to "http://127.0.0.1:1080/WebTours/reservations.pl", Target Frame=""          [MsgId: MMSG-27978]
    Action.c(29): Resource "http://127.0.0.1:1080/WebTours/images/button_next.gif" is in the cache already and will not be downloaded again          [MsgId: MMSG-26655]
    Action.c(29): web_submit_form("reservations.pl_2") was successful, 3661 body bytes, 253 header bytes          [MsgId: MMSG-26386]
    Action.c(36): 60Ending action Action.

    而我想日志只要输入这个lr_output_message("%s",lr_eval_string("{passengers}"));的结果,其他过程在日志中都不显示,
    期望显示为:
    Action.c(36): 64
    Action.c(36): 12
    Action.c(36): 60
    ----这样看直观,一目了然
    分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
    收藏收藏
    回复

    使用道具 举报

    该用户从未签到

    4#
    发表于 2011-4-22 11:33:02 | 只看该作者
    你要一目了然用lr_error_message

    记得用完了删掉
    回复 支持 反对

    使用道具 举报

  • TA的每日心情
    奋斗
    2018-6-19 15:14
  • 签到天数: 27 天

    连续签到: 1 天

    [LV.4]测试营长

    3#
     楼主| 发表于 2011-4-22 11:22:53 | 只看该作者
    回复 2# patrick_1984


       你好,我没有看到“log disable"这个选项呀?
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    2#
    发表于 2011-4-22 10:54:11 | 只看该作者
    回放选项里,把log disable就可以了。
    回复 支持 反对

    使用道具 举报

    本版积分规则

    关闭

    站长推荐上一条 /1 下一条

    小黑屋|手机版|Archiver|51Testing软件测试网 ( 沪ICP备05003035号 关于我们

    GMT+8, 2024-11-11 05:13 , Processed in 0.079340 second(s), 28 queries .

    Powered by Discuz! X3.2

    © 2001-2024 Comsenz Inc.

    快速回复 返回顶部 返回列表