Configure Load Tests in Test Studio
When attempting to perform load testing on a web application, the process entails more than just recording and replaying a web test. It involves meticulous adjustments to ensure only essential requests are included, dynamic identifiers are properly handled, and user behavior is realistically simulated.
This KB article also answers the following questions:
- How do I remove unnecessary requests from my load test in Test Studio?
- What are dynamic targets in Test Studio and how do I use them?
- How do I simulate real user behavior in load testing with Test Studio?
To set up a load test for a web application in Test Studio, follow these steps:
User Profile in Load Test
Start by creating a user profile. This will capture the HTTP(S) requests generated during the web test scenario.
Review the captured traffic and remove requests that load visual resources (e.g., JS scripts, CSS, images) from the user profile. Load test does not interact with the application UI so this type of requests are not needed.
Usually in the recorded traffic some of the HTTP requests load resources from other sources - like google analytics, fontawesome, or any other 3rd party providers. Remove such requests from the user profile as these are not needed for loading the tested application server.
Managing Dynamic Targets
Dynamic targets allow parameterization of captured traffic. This is essential for each virtual user to initiate a valid user session recognized by the server.
Identify dynamic targets based on the captured traffic, ensuring each virtual user initiates a valid user session throughout the complete user profile. This involves finding the dynamic identifiers such as cookies, headers, query parameters, etc., used in authentication and subsequent requests.
Add dynamic targets by selecting the source step and destination step, defining how the dynamic value will be reused (e.g., as a header, query parameters, or cookie). For detailed instructions, visit the dynamic targets documentation.
For detailed guidance on identifying and adding dynamic targets, see the blog post on custom dynamic targets in load tests.
Additional Settings
- Add think times to simulate real user behavior, such as delays between page loads and actions. Modify these settings as detailed in the modifying tests section.
Running the Load Test
Initially, run the test with 1 user for 1 minute to ensure the profile is correctly set up. Once confirmed, increase the number of users as needed. See additional details for load test settings.
Follow the best practices for running load tests.
Additional Resources
- Test Studio Step-by-Step: Load Testing
- Start Load Testing. Now. Really.
- Designing Load Tests with Test Studio and Fiddler Everywhere in 6 Easy Steps