Jmeter-Maven-Plugin高级应用:Adding additional libraries to the classpath
Adding additional libraries to the classpath
Pages 12
Adding jar's to the /lib/ext directory
You can add any additional Java libraries to JMeter's lib/ext directory by using the<jmeterExtensions>
configuration element. This uses the Eclipse Aether libraries to perform dependency resolution.
+---+
<project>
[...]
<build>
<plugins>
<plugin>
<groupId>com.lazerycode.jmeter</groupId>
<artifactId>jmeter-maven-plugin</artifactId>
<version>2.0.3</version>
<executions>
<execution>
<id>jmeter-tests</id>
<goals>
<goal>jmeter</goal>
</goals>
</execution>
</executions>
<configuration>
<jmeterExtensions>
<artifact>kg.apc:jmeter-plugins:pom:1.3.1</artifact>
</jmeterExtensions>
</configuration>
</plugin>
</plugins>
</build>
[...]
</project>
+---+
Adding jar's to the /lib/junit directory
You can add any additional Java libraries to JMeter's lib/junit directory by using the<junitLibraries>
configuration element. This uses the Eclipse Aether libraries to perform dependency resolution.
+---+
<project>
[...]
<build>
<plugins>
<plugin>
<groupId>com.lazerycode.jmeter</groupId>
<artifactId>jmeter-maven-plugin</artifactId>
<version>2.0.3</version>
<executions>
<execution>
<id>jmeter-tests</id>
<goals>
<goal>jmeter</goal>
</goals>
</execution>
</executions>
<configuration>
<junitLibraries>
<artifact>com.lazerycode.junit:junit-test:1.0.0</artifact>
</junitLibraries>
</configuration>
</plugin>
</plugins>
</build>
[...]
</project>