karatelabs / karate

Test Automation Made Simple

Home Page:https://karatelabs.github.io/karate

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Doubt regarding afterScenario and afterFeature

Shivansh-1174 opened this issue · comments

I have a doubt regarding the afterScenario and afterFeature in karate . In case my actual scenario fails and I have configured afterScenario and afterFeature , does they still execute???

In my case I have a Scenario and I have configured afterScenario to do some cleanup task but when my scenario fails the afterScenario is not executed .

I am assuming it should execute even if there is a failure in the actual scenario otherwise what is the use of afterScenario for clean up purpose.

Same doubt for afterFeature as well.

please ask such questions on stack overflow, also see: https://stackoverflow.com/a/60944060/143475