This repository show to use k6 to create Load and Stress tests.
-
Load Test: Is a type of Performance Testing used to determine a system's behavior under both normal and peak conditions. Load Testing is used to ensure that the application performs satisfactorily when many users access it at the same time.
-
Stress Test: Is a type of load testing used to determine the limits of the system. The purpose of this test is to verify the stability and reliability of the system under extreme conditions.
To install k6, follow the steps of the installation guide
Running Load Test:
$ k6 run load_test\script.js
Running Stress Test:
$ k6 run stress-test\stress-test-script.js
Inspect the k6 end-of-test summary. In console, we can see the print of summary report to stdout that contains a general overview of your test results. For example:
In example above, we can see the execution context, any logs of my script (when the response is longer than expected) and the checks result.
- Create GithubAction workflow to execute k6 tests
- Send results and alerts to Slack Channel