vendredi 27 avril 2018

After Scenario Outline hook in Cucumber

I'm using Java and Cucumber. I need to do some actions after every scenario outline. I know there are @Before and @After hooks, but they are applicable to every scenario in Scenario Outline. Is there any possibility to launch some actions exactly after all scenarios in outline and not after every scenario?

Example:

   Scenario Outline: Some scenario
   Given given actions
   When when actions
   Then display <value>
Examples:
|value|
|a    |
|b    |

I want to make execution in following way:

@Before actions

a value

b value

@After actions

@Before actions

//another scenario outline output

@After actions

Aucun commentaire:

Enregistrer un commentaire