Cucumber is a BDD framework and we use Gherkin language to create scenarios. Cucumber is a useful tool for mobile and web application testing. To achieve this, we define ‘Features and Steps Definition’ files in the appropriate directory structure. We can categorize feature files using various tags and use multiple tags in a feature file.
-
Below is the cucumber command to execute cucumber feature files:-
cucumber --tags "@smoke and @regression"This command will execute all feature files having "@smoke and @regression" tags. -
Cucumber can also ignore scenarios with a particular tag. For example:-
cucumber --tags "not @smoke"This command will execute all other feature files except the ones having a "@smoke" tag. -
To list out available options for cucumber execution, please use below-mentioned command:-
cucumber --help
Post a Comment