I have a test project built in Intellij IDEA 2021.1 using Selenium, Cucumber and Maven The project runs fine from within Intellij but now I want to call the tests from the command line and only those with a specific tag. Below is the project layout
There is only 1 feature file at present and I only want to call the scenarios with the "regression" tag from the command line.
I have run command line with Visual Studio/Selenium in the past but this is my first go with Java so any advice on how to get this started would be great.
you can try this command:
mvn clean install "-Dcucumber.options=--tags @yourtagName"
try to execute following
mvn verify -Dcucumber.options="--tags not @ignore"
Or
mvn verify -Dcucumber.options="--tags @runme"
where @runme is a tag over Scenario or Feature.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.