Loading challenge...
Run real mini load test
Configure your load test parameters
Request history
Note: This is a real load test running in your browser. For production load testing, use dedicated tools like k6, Locust, or Artillery running from a separate machine.
Testing hints
// Monitor load test results
await page.fill('input[type="text"]', '/api/test');
await page.click('text=Start Load Test');
// Wait for test completion
await expect(page.locator('text=Final Results'))
.toBeVisible({ timeout: 35000 });
// Verify stats are populated
const rps = await page.locator('text=Requests/sec')
.locator('..')
.locator('.text-yellow-400')
.textContent();
expect(parseFloat(rps || '0')).toBeGreaterThan(0);
// Check success rate
const successRate = await page.locator('text=Success Rate')
.locator('..')
.locator('.text-green-400, .text-red-400')
.textContent();import http from 'k6/http';
import { check, sleep } from 'k6';
export const options = {
vus: 10,
duration: '30s',
thresholds: {
http_req_duration: ['p(95)<500'],
http_req_failed: ['rate<0.01'],
},
};
export default function() {
const res = http.get('http://localhost:3002/api/test');
check(res, {
'status is 200': (r) => r.status === 200,
'response time < 500ms': (r) => r.timings.duration < 500,
});
sleep(0.1);
}