NavyCody
NavyCody

Reputation: 492

Integration of Karma test cases in Jenkins which is configured to run ansible script

We are stuck with a scenario where we deploy code(written in nodejs) to remote instance through ansible scripts. We now have to integrate this code in jenkins server.

Till now we ran the pure ansible script in EXECUTE SHELL section of job configuration.

But now ,we need to run a series of karma test cases and upon success execute this ansible script. We have tried running karma test cases inside ansible script but that means giving control to ansible and missing reporting feature which jenkins does.

What we need is a test runner plugin of jenkins that would run test cases and upon success run this ansible script and upon failure do appropriate reporting. Any working example would be highly helpful.

Upvotes: 0

Views: 905

Answers (1)

Kashyap
Kashyap

Reputation: 17451

And why doesn't the good old Conditional step work for you?

Add build step -> Conditional (Single)

Add build step -> Conditional (Single)

Upvotes: 2

Related Questions