k6 Rules
Modern load testing tool using JavaScript. Write performance tests as code and catch regressions before production.
3 rules
Response Validation with Checks
Beginner
Require check() calls for every HTTP request in k6 scripts — validate status codes, response bodies, and headers to catch functional failures under load.
globs: **/*.k6.js, **/k6/**, **/load-test*, **/perf-test*
checks, response-validation, assertions, functional-testing
View Rule
Mandatory Think Time Between Requests
Beginner
Require sleep() calls between k6 HTTP requests to simulate realistic user behavior — prevent artificial burst traffic that skews performance results.
globs: **/*.k6.js, **/k6/**, **/load-test*, **/perf-test*
think-time, sleep, realistic-load, user-behavior
View Rule
Mandatory Threshold Configuration
Beginner
Require performance thresholds in every k6 script — p95 response time, error rate, and check pass rate must be defined for automated pass/fail in CI pipelines.
globs: **/*.k6.js, **/k6/**, **/load-test*, **/perf-test*
thresholds, performance-criteria, pass-fail, slo
View Rule