This repository is a tutorial on how to test the performance of an API using Apache JMeter
In this video, I'll show you how to performance test your API using Apache JMeter. This video focuses on Load Testing, Stress Testing, Endurance Testing, and Peak Testing. In a real-world scenario, we would use significantly more threads (users), and the tests would run for longer periods. However, since this is just a demonstration video, smaller values have been used.
API used on the video: https://catfact.ninja/
Make sure to install Apache JMeter on your machine and open the following Test Plan inside JMeter: CatFactsTestPlan.jmx
To run on non-GUI mode:
- Create an empty folder for each testing type to store your report (i.e:
load_report,stress_report,endurance_report,spike_report) - Disable all the threading groups, except for the one corresponding to the test type you want to execute and then run:
jmeter -n -t CatFactsTestPlan.jmx -l load.jtl -e -o load_report
or
jmeter -n -t CatFactsTestPlan.jmx -l stress.jtl -e -o stress_report
or
jmeter -n -t CatFactsTestPlan.jmx -l endurance.jtl -e -o endurance_report
or
jmeter -n -t CatFactsTestPlan.jmx -l spike.jtl -e -o spike_report
Happy testing!
