DEV Community

Raghwendra Sonu
Raghwendra Sonu

Posted on

How to run JMeter test from Jenkins?

Step 1 : Install Jenkins
https://jenkins.io/doc/book/installing/

Step 2 : Install Performance Plugin in Jenkins from Manage Jenkins Options.

Step 3 : Goto Jmeter/bin folder open user.properties file and add line :
jmeter.save.saveservice.output_format=xml

Step 4 : Create a Jmeter test

Step 5 : Add a job in Jenkins - add below jmeter commands in build step

cd C:\Automation\Softwares\apache-jmeter-5.1.1\apache-jmeter-5.1.1\bin
jmeter -n -t “location of the jmeter script” -l “location of result file”
-e -o “location of the output folder”

example:

jmeter -n -t F:\DevelopmentPrograms\LoadTest\FTP_LoadTest.jmx -l
F:\DevelopmentPrograms\LoadTest\Results\result.csv -e -o F:\DevelopmentPrograms\LoadTest\Results

Step 6 : Add post build action - publish performance test reports

Step 7 : Run and validate

That's it.

Top comments (0)