美文网首页
jmeter树形html报告生成

jmeter树形html报告生成

作者: Mlotjve | 来源:发表于2018-11-15 09:43 被阅读0次

    1、下载style文件:jmeter.results.shanhe.me.xsl

    1. 把下载文件放到jmeter的extras目录下

    2. 修改jmeter.properties

    jmeter.save.saveservice.output_format=xml

    image.png

    并修改如下字段:

    # assertion_results_failure_message only affects CSV output
    jmeter.save.saveservice.assertion_results_failure_message=true
    #
    # legitimate values: none, first, all
    #jmeter.save.saveservice.assertion_results=none
    #
    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
    
    1. 修改build.xml文件,如下第7行style的值修改为新下载的xsl文件名:

    替换: style="${basedirectory}/jmeter-results-shanhe-me.xsl">

     <target name="report">
                <tstamp> <format property="report.datestamp" pattern="yyyy/MM/dd HH:mm" /></tstamp>
                <xslt classpathref="xslt.classpath"  
                      force="true"  
                      in="${jmeter.result.jtlName}"  
                      out="${jmeter.result.htmlName}"  
              
                      style="${basedirectory}/jmeter-results-shanhe-me.xsl">
    
                      <param name="dateReport" expression="${report.datestamp}"/>
                </xslt>
                <copy todir="${jmeter.result.html.dir}">
                    <fileset dir="${jmeter.home}/extras">
                        <include name="collapse.png" />
                        <include name="expand.png" />
                    </fileset>
                </copy>
            </target>
    
    image.png

    相关文章

      网友评论

          本文标题:jmeter树形html报告生成

          本文链接:https://www.haomeiwen.com/subject/btpefqtx.html