One of the most common challenges in every test project is the test data management. Data is typically spread across multiple databases in today’s business world and it’s hard to manage its complexity. Working with clean data is crucial when it comes to performance testing however realistic and reliable data is hard to create. In this post, the 3 most significant tips about how to work with CSV files in JMeter will be revealed.
Before you start performance testing, you should consider how to maintain the data. Performance tests are very challenging since you simulate thousands of users on your application. It requires you to consume so much data in a short period of time. It’s very hard to revert the data to its old state when you need it. So you need to come up with a good strategy to handle the data successfully.
One other thing to consider in a performance test project is the caching mechanism. When you run a test with the same data, there’s a good chance that the app will start to cache the response. So your request won’t reach the server. For this reason, we can conclude that you need a variety of data.
JMeter lets you deal with data by using CSV files. Here are some tips about CSV usages;
Tip #1 Try to use the data as dynamic as possible
Browsing a website, filtering data in a website are good examples. Your data is on a website or an application, you just need to use this data by using your CSS or JQuery Extractors as told in this article (https://loadium.com/using-css-selectors-in-jmeter-scripts/) and randomize your actions. If you have a pagination, determine how many pages you have and try to navigate the last ones. You will definitely bypass the caching mechanism.