0

I want to add Jmeter tests as build steps in TeamCity server. If tests fail, a build will not complete. Please share how to do it.

I am currently using Jmeter for testing a Rest API running different scenarios/threads on a standalone machine. My intention is to put these tests in our existing CI/CD that has TeamCity. When we deploy a new release, Jmeter tests will run as automation tests and if any test fails, then the build will roll back and generate failure reports.

  • 1
    WHat have you tried? What problems are you experiencing? – Kate Paulk Mar 6 at 19:40
  • I am currently using Jmeter for a Rest API running different scenarios/threads. My intention is to put these tests in our existing CI/CD that has TeamCity. When we deploy a new release, jmeter tests will run and if any test fails, then the build will roll back and generate failure reports – QA-Tester Mar 7 at 21:44
0

The easiest solution would be returning a non-zero exit status code in case if there are failures in JMeter tests.

It can be achieved by running your JMeter tests via Taurus tool which provides possibility to add Pass/Fail Criteria and in case if the criteria are not met, the test execution will fail and TeamCity capture the script return code and correspondingly fail the build.

References:

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.