Forum Discussion

bcoelho2000's avatar
bcoelho2000
New Contributor
8 years ago
Solved

How to invoke a REST API (e.g. JIRA REST API) when a test case assertion fails?

Hi everyone! The title is self-explanatory but basically what I want to do is to call/invoke a REST API (in this case from JIRA) whenever a test case fails (assertion is different from what is e...
  • bcoelho2000's avatar
    bcoelho2000
    8 years ago

    I was looking for "as soon as the assert fails". 

     

    What I did was using a "Conditional GO" after the assert and then jump to a final step (just a delay step). If the assert fails, the Conditional GO will also fail, therefore it will execute the next step which is a REST API call to JIRA. Else, it will jump over the REST API call straight to the Delay step