jmeter +ant 详细报告
作者:互联网
注意:
1.jmeter +ant 均基于jdk;
2.以下内容,假定大家会用jmeter做简单接口测试;
3.本文主要是生成 jmeter +ant 详细报告
步骤:
1. 将 jmeter_home\extra\ant-jmeter-1.1.1.jar 复制到 ant_home\lib 下;
2.新建一个独立的目录(比如 ants)用来存放 .jmx 和报告 ants\jtl , ants\html;
3.复制 jmeter_home\extra\build.xml 文件到 .jmx 的同一个目录;
4.打开build.xml 文件修改相关配置生成 汇总报告 和 详细报告;
5.运行:cmd-> 到独立目录 ants ,直接输入 ant 回车即可;
详细报告:
1.需要下载模板文件jmeter.results.shanhe.me.xsl 并放置到 jmeter home 下extras目录下;
2.修改jmeter.properties 部分值;
jmeter.save.saveservice.data_type=true
jmeter.save.saveservice.label=true
jmeter.save.saveservice.response_code=true
# response_data is not currently supported for CSV output
jmeter.save.saveservice.response_data=true
# Save ResponseData for failed samples
jmeter.save.saveservice.response_data.on_error=false
jmeter.save.saveservice.response_message=true
jmeter.save.saveservice.successful=true
jmeter.save.saveservice.thread_name=true
jmeter.save.saveservice.time=true
jmeter.save.saveservice.subresults=true
jmeter.save.saveservice.assertions=true
jmeter.save.saveservice.latency=true
# Only available with HttpClient4
jmeter.save.saveservice.connect_time=true
jmeter.save.saveservice.samplerData=true
jmeter.save.saveservice.responseHeaders=true
jmeter.save.saveservice.requestHeaders=true
jmeter.save.saveservice.encoding=false
jmeter.save.saveservice.bytes=true
# Only available with HttpClient4
jmeter.save.saveservice.sent_bytes=true
jmeter.save.saveservice.url=true
jmeter.save.saveservice.filename=true
jmeter.save.saveservice.hostname=true
jmeter.save.saveservice.thread_counts=true
jmeter.save.saveservice.sample_count=true
jmeter.save.saveservice.idle_time=true
下载地址:http://shanhe.me/2011/06/07/new-xsl-stylesheet-for-jmeter-command-line-results-report
下载碰到的坑:家里的wifi 网页不能完全打开,数据流量下载很快;
本人碰到的难点在 build.xml, 文件内容如下
生成的详细报告:
标签:jmeter,saveservice,ant,详细,save,true,truejmeter 来源: https://www.cnblogs.com/xj63183/p/15666718.html