This is a set of k6 load tests related to the integration of the Green Pass.
This test represents the submit of a message to a user. It uses fiscal code selected randomly from an array of pre approved test fiscal code which is populated in config.json. The Message Status is sampled, with a percentage defined in the config.json file.
You need to set an environment variable APIM_KEY
with the azure API Management Subscription key.
You need to set an environment variable BASE_URL
for the base url API.
k6 run \
-e APIM_KEY=${APIM_KEY} \
-e BASE_URL=${BASE_URL} \
-e FISCAL_CODES=${FISCAL_CODES} \
-e MESSAGE_SAMPLING_RATE=${MESSAGE_SAMPLING_RATE} \
src/submit_message.js
# or
docker run -i --rm -v $(pwd)/src:/src \
-e APIM_KEY=${APIM_KEY} \
-e BASE_URL=${BASE_URL} \
-e FISCAL_CODES=${FISCAL_CODES} \
-e MESSAGE_SAMPLING_RATE=${MESSAGE_SAMPLING_RATE} \
loadimpact/k6 run /src/submit_message.js
todo
You need to set an environment variable BASE_URL
for the base url API.
k6 run -e BASE_URL=${BASE_URL} src/get_certificate.js
# or
docker run -i --rm -v $(pwd)/src:/src -e BASE_URL=${BASE_URL} loadimpact/k6 run /src/get_certificate.js