cucumber-jvm: Cannot pass tag expression to maven-surefire-plugin
Summary
The new multi-token expression syntax makes it impossible to declare multi token tag expression in the --tags flag inside the -Dcucumber.options flag in maven-surefire-plugin configuration.
Expected Behavior
It should be possible possible to pass multi token tag expression in the -Dcucumber.options flag.
Current Behavior
maven-surefire-plugin crashes throwing either VM crash, IllegalArgumentException or doesn’t run any tests depending on the input.
Possible Solution
Make it possible to make single token tag expression without any whitespace characters.
Steps to Reproduce (for bugs)
- Create a basic cucumber project using maven with maven-surefire-plugin
- In the pom.xml define argLine tag inside maven-surefire-plugin configuration
- Inside argLine tag add -Dcucumber.options=" --tags ‘not @ignored’" or -Dcucumber.options=’ --tags “not @ignored”’
- run
mvn test
Context & Motivation
My use case is injecting tag expression from parent pom.
Your Environment
- Version used: 3.0.2
- Operating System and version: Linux Mint 19
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 15 (8 by maintainers)
Looks like this fixed properly in maven-shared-utils/33659 but hasn’t made it into the latest Surefire yet. It will be a matter of patience.