Dcucumber.options, how to have multiple tags

喜夏-厌秋 提交于 2019-11-30 02:05:41

To run scenarios with @debug1 and @debug2:

mvn test -Dcucumber.options="--tags @debug1 --tags @debug2"

To run scenarios with @debug1 or @debug2:

mvn test -Dcucumber.options="--tags @debug1,@debug2"

Little late to the party, but I am using something like:

mvn test -D tags="debug1 and debug2"

I am on Cucumber 2.4.

The @ symbol is optional. You can use a tags Maven property. And you can use boolean logic to hook up multiple tags - official docs.

Reduces the amount of typing little bit.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!