Hey there, performance testers! Tired of handcrafting your JMeter scripts? Well, buckle up, because JMeter has a sweet trick up its sleeve called script recording. Skip the manual coding and let JMeter capture your app clicks like a digital detective. It translates these clicks into a script filled with all the JMeter elements you need. Record your scenario in JMeter and upload it on Azure load Testing for analysing your application’s performance.
Ready to see how it works? Let's dive in!
STEPS TO PERFORM JMETER RECORDING
For the purpose of our demonstration, we will be load testing our web application, an online shopping application called Contoso Traders. Let’s go.
CREATE A JMETER TEMPLATE
(?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2)
with
(?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2|svg)
INSTALL JMETER CA CERTIFICATE
Once you click on Start, a JMeter proxy server is started, which is used to intercept the browser requests. A file called ApacheJMeterTemporaryRootCA.crt will be generated in JMETER_HOME/bin folder. You need to install this certificate by following the steps mentioned here - Installing the JMeter CA certificate for HTTPS recording.
Since we are using Chrome browser for recording, we have installed the certificate by opening ApacheJMeterTemporaryRootCA.crt stored in JMETER_HOME/bin. Click on the "Details" tab and check that the certificate details agree with the ones displayed by the JMeter Test Script Recorder. If OK, go back to the "General" tab, and click on "Install Certificate …" and follow the Wizard prompts.
CONFIGURE YOUR BROWSER TO USE THE JMETER PROXY
If you are recording on Firefox, you can follow these steps.
For Chrome or Edge, you can follow these steps-
RECORD YOUR NAVIGATION
Voila! Your test script is effortlessly generated from the sequence of user actions performed.
UPLOAD ON AZURE LOAD TESTING
You can run your script on our fully-managed service – Azure Load Testing. The service ensures that you can scale effortlessly, integrate testing in your CI/CD pipelines and consume your test results to improve your system performance. Just follow these steps to upload and run your script.
Happy testing!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.