jmeter-maven-plugin

工程目录:

jmeter-maven-plugin_第1张图片

Maven pom.xml:

xml version="1.0" encoding="UTF-8"?>
xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    4.0.0

    shanghai
    jmeter
    1.0-SNAPSHOT

    
        UTF-8
    

    
        
            
                com.lazerycode.jmeter
                jmeter-maven-plugin
                2.6.0
                
                    
                        jmeter-tests
                        
                            jmeter
                        
                    
                
                
                    true
                
            
        
    

在src/test下新建文件夹jmeter,

把51Testing.jmx测试脚本复制到该文件夹,

再把jmeter.properties、saveservice.properties、system.properties、upgrade.properties、user.properties

也复制到该文件夹,

执行命令:mvn verify


查看测试报告:

jmeter-maven-plugin_第2张图片

你可能感兴趣的:(JMeter)