A fast-loading site keeps users engaged, drives higher conversion rates, and even improves search engine rankings. This guide will walk you through a practical approach to load testing a WordPress site hosted on Rapyd Cloud using LoadForge.
We're excited to announce a powerful new feature for LoadForge users: comprehensive debug logging for test runs. This highly requested capability makes it easier than ever to troubleshoot, validate, and understand what's happening during your load tests.What's NewWith this update, you can now use simple Python print() statements in your...
TLDR: LoadForge has introduced enhanced file management for load tests, allowing users to upload and manage data files like CSV, JSON, and TXT, which can be integrated into scripts for more realistic, data-driven testing.
•2 min read
We're excited to announce a powerful new addition to LoadForge: enhanced file management capabilities for your load tests. This feature allows you to upload, create, and manage data files that can be seamlessly integrated into your load testing scripts.
Why We Added File Management
Load testing often requires realistic data to simulate user behavior accurately. Whether you're testing authentication systems with thousands of user credentials, submitting forms with varied input data, or configuring complex API test scenarios, having access to structured data files can significantly improve the quality and realism of your tests.
Based on your feedback, we've implemented a robust file management system that makes it easy to incorporate data-driven testing into your LoadForge projects.
How It Works
Files uploaded through our intuitive interface are automatically distributed to all your load generators and stored in a dedicated files/ directory. Your Locust scripts can then access these files using standard file operations, making it simple to:
Load user credentials from JSON files
Read test data from CSV files
Configure test parameters using configuration files
Support for Multiple Formats: Upload CSV, JSON, or TXT files (up to 5MB)
Intelligent Editing: Our system recognizes file types and provides appropriate editing capabilities (CSV editor for .csv files, etc.)
Seamless Integration: Files are automatically available on all load generators without any additional configuration
Persistent Storage: Your files remain available for future test runs
Practical Examples
Here's a quick example of how you might use a JSON file containing user credentials in your Locust test:
def on_start(self):
# Load user credentials from the uploaded JSON file
with open('files/userlist.json', 'r') as f:
self.users = json.load(f)
<pre><code># Select a random user for this test
user_data = random.choice(self.users)
self.username = user_data['username']
self.password = user_data['password']