Forum Discussion
KaranRaju
New Contributor
I just wanted to know whether there is any method to determine individual example status instead of scenario status.
aurelien-reeves
3 years agoStaff
Ok, thanks for the clarification.
This is actually not supported by Cucumber.
Would you need that for altering the state while your test is executing? Or for reporting purpose?
If you want to alter the state of your test execution, this is actually a bad idea. It is good testing practices to start from a clean state for each and every executed test.
If this is for reporting purpose, hooks are not the good tools for that. As you can see there: https://github.com/cucumber/cucumber-jvm/blob/a64adbe2264dab2d4a5ee0f2d92d1b193b800a18/java/src/main/java/io/cucumber/java/Scenario.java, a custom formatter using the plugin system would be a better choice.
Related Content
Recent Discussions
- 4 months agopz1502
- 5 months agoraja110199