gatlingExecuteTests¶
Description¶
In this step Gatling performance tests are executed. Requires the Jenkins Gatling plugin to be installed.
Prerequisites¶
The Gatling Jenkins plugin needs to be installed.
Parameters¶
name | mandatory | default | possible values |
---|---|---|---|
appUrls |
no | ||
failOnError |
no | true , false |
|
pomPath |
yes | ||
script |
yes |
appUrls
- Optional List of app URLs and corresponding Jenkins credential IDs.failOnError
- Defines the behavior in case tests fail. When this is set totrue
test results cannot be recorded using thepublishTestResults
step afterwards.pomPath
- Path to the pom.xml file containing the performance test Maven module, for exampleperformance-tests/pom.xml
.script
- The common script environment of the Jenkinsfile running. Typically the reference to the script calling the pipeline step is provided with thethis
parameter, as inscript: this
. This allows the function to access thecommonPipelineEnvironment
for retrieving, e.g. configuration parameters.
Step configuration¶
We recommend to define values of step parameters via config.yml file.
In following sections of the config.yml the configuration is possible:
parameter | general | step/stage |
---|---|---|
appUrls |
X | |
failOnError |
X | |
pomPath |
X | |
script |
We recommend to define values of step parameters via config.yml file.
Dependencies¶
The step depends on the following Jenkins plugins
- credentials-binding
- gatling
- pipeline-utility-steps
- workflow-basic-steps
- workflow-cps-global-lib
- workflow-durable-task-step
Transitive dependencies are omitted.
The list might be incomplete.
Consider using the ppiper/jenkins-master docker image. This images comes with preinstalled plugins.
Example¶
Pipeline step:
gatlingExecuteTests script: this, pomPath: 'performance-tests/pom.xml'