I can't solve it yet, but a much cleaner way seemed like doing this:

- maven.test.skip=true by default in the pom
- make a profile databaseAvailable in settings.xml and activate it by default
- reuse that profile in the default pom to maven.test.skip=false

Now the problem is "mvn -Dmaven.test.skip=true install" still doesn't work because the profile system property wins over the command line system property. Is this a known bug?


With kind regards,
Geoffrey De Smet

Geoffrey De Smet schreef:
Hi,

I'd like to skip the tests for my build if no database is available.
When a database is available, the developer puts in an active profile in his settings.xml with property:
  <database.available>true</database.available>

Can I configure the surefire plugin's like this:

<skip>${${maven.test.skip} || !${database.available}}</skip>
so skip the tests if maven.test.skip is on or if the database is not available.

This way even developers with a database can skip them by using the all known command "-Dmaven.test.skip"



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to