Has anyone tried to fail the Jenkins Job when Gatling statements fail, or if the requests fail?
For instance:
- mark Jenkins as unstable when the global average for the 95th percentile is below a certain value, say 1.2 sec for response time
- mark the Jenkins build unsuccessful if a certain percentage of requests did not respond
Does anyone have an idea how this can be achieved using existing Maven / Jenkins Gatling plugins.
My maven plugin settings:
<plugin> <groupId>io.gatling</groupId> <artifactId>gatling-maven-plugin</artifactId> <version>${gatling.version}</version> <configuration> <failOnError>true</failOnError> <simulationsFolder>src/test/scala</simulationsFolder> <runMultipleSimulations>true</runMultipleSimulations> <configFolder>src/main/resources</configFolder> </configuration> <executions> <execution> <id>GoOrBust</id> <phase>test</phase> <goals> <goal>execute</goal> </goals> <configuration> <simulationClass>mine.OnePunch</simulationClass> <failOnError>true</failOnError> </configuration> </execution> </executions> </plugin>
<failOnError>true</failOnError> will only affect the generation of the report, but not the work of Jenkins (obviously).
I would prefer to not explicitly exclude exceptions from the tests, performing individual control / handling of exceptions.
source share