| `K6_IMAGE` | The Docker image used to run k6 | `loadimpact/k6:latest` |
| `K6_TESTS_DIR` | The k6 tests directory | `k6` |
| `K6_EXTRA_ARGS` | k6 extra [command-line](https://k6.io/docs/getting-started/running-k6) | _none_ |
| `REVIEW_ENABLED` | Set to enable k6 tests on review environments (dynamic environments instantiated on development branches) | _none_ (disabled) |
### Unit tests report integration
### Load performance report integration
XXX test reports are [integrated to GitLab by generating JUnit reports](https://docs.gitlab.com/ee/ci/junit_test_reports.html).
k6 test reports are [integrated to GitLab by generating load performance reports](https://docs.gitlab.com/ee/user/project/merge_requests/load_performance_testing.html).
This is done using the following CLI options: `--junit --output=reports/`
This is done using the following CLI options: `--out json=reports/`
### Base URL auto evaluation
By default, the XXX template tries to auto-evaluate the base URL (i.e. the variable pointing at server under test) by
By default, the k6 template tries to auto-evaluate the base URL (i.e. the variable pointing at server under test) by
looking either for a `$environment_url` variable or for an `environment_url.txt` file.
Therefore if an upstream job in the pipeline deployed your code to a server and propagated the deployed server url,
either through a [dotenv](https://docs.gitlab.com/ee/ci/pipelines/job_artifacts.html#artifactsreportsdotenv) variable `$environment_url`
or through a basic `environment_url.txt` file, then the XXX test will automatically be run on this server.
or through a basic `environment_url.txt` file, then the k6 test will automatically be run on this server.
:warning: all our deployment templates implement this design. Therefore even purely dynamic environments (such as review
environments) will automatically be propagated to your XXX tests.
environments) will automatically be propagated to your k6 tests.
In order to use the auto-evaluated base URL, you shall use the `base_url` environment variable from your k6 scripts.
If you're not using a smart deployment job, you may still explicitly declare the `XXX_BASE_URL` variable (but that
will be unfortunately hardcoded to a single server).