I have a weird request; I'm not sure if its even possible.
I have loads of scenarios that I have defined using Scenario Outline but I don't want all of them to run on our CI environment as it will slow down the build.
Is it possible to randomise the selection of examples and have it limited to a number that is configurable so that I only execute those number of scenarios at a time. I am not expecting Gherkin to do this but using Java before the control is passed on to Cucumber.
We use a JUnit runner to run our cucumber tests, so just want to know if its possible to build the list of scenarios at that point and start the test.
Any help in this is greatly appreciated.
Thank you
Please see tagging the cucumber scenarios.
Then you can specify tags for scenarios you want to be executed. A single tag may be used for more than one scenario.
E.g :
@nightly Scenario: Calculator Add Given I add X and Y ....
command line : cucumber --tags @nightly