You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2022/06/06 15:22:39 UTC

[GitHub] [maven-surefire] chalmagr commented on pull request #476: [SUREFIRE-2010] Parameterized Selection Does not Work

chalmagr commented on PR #476:
URL: https://github.com/apache/maven-surefire/pull/476#issuecomment-1147570883

   > Thanks for the hints. I adapted the code, but is there any part of the maven launcher which allows to pass something like `-Dtest=MySelector`, or do I have to call it myself? Just adding it as goal ends in
   > 
   > ```
   > [ERROR] Unknown lifecycle phase "test -Dtest=ExampleTestJUnit4". You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id>[:<plugin-version
   > >]:<goal>. Available lifecycle phases are: validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, g
   > enerate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy, pre-cle
   > an, clean, post-clean, pre-site, site, post-site, site-deploy. -> [Help 1]
   > ```
   > 
   > I can debug this with `-Dmaven.surefire.debug=true`, but that does not help to create the process correctly.
   
   Make sure to use org.apache.maven.surefire.its.fixture.SurefireLauncher#sysProp to add the option and not the execute method `execute("test -Dtest=...")`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org