I had another thought, in the configuration section of each pom, couldn't I do something like this:
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <configuration> <skip>${modulename.test}</skip> </configuration> </plugin> Then in the profiles.xml file, the default active profile could have all the ${module.name} equal to false and people could use their profiles in their settings.xml to set these to true if they want to skip? -----Original Message----- From: Heck, Joe [mailto:[EMAIL PROTECTED] Sent: Thursday, December 07, 2006 4:49 PM To: Maven Users List Subject: RE: skipping tests Heh - I know the feeling. I'm basing this on some examples and discussion I found on running functional tests integrated into a Maven2 build. Not exactly what you're wanting, but the "on/off" switch mechanism could be used almost identically. I'm not a guru on making profiles work, but the gist would be to put all the unit tests into a module under your master build, and instead of defining them in the <modules>...</modules> XML stanza of the POM, set it up in the <profiles>...</profiles> section. As an example: <modules> <module>example-jar</module> <module>example-war</module> </modules> ... <profiles> <profile> <id>functional-test</id> <activation> <property> <name>enableCiProfile</name> <value>true</value> </property> </activation> <modules> <module>functional-test</module> </modules> </profile> </profiles> And then when you wanted to invoke including that module in the "build", you'd simple invoke the profile on the command line. i.e. mvn clean test -P functional-test Does that help? -joe -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of EJ Ciramella Sent: Thursday, December 07, 2006 12:42 PM To: Maven Users List Subject: RE: skipping tests Sorry - this makes my eyes go googly - can you explain a bit more in detail? We have everything modularized, but typically build from the topmost level of the project. I was hoping to find a -Dmaven.test.skipthese=<somelist> kind of a solution. >From the commandline would be the best option. Specifying a profile via the commandline would be second best. -----Original Message----- From: Heck, Joe [mailto:[EMAIL PROTECTED] Sent: Thursday, December 07, 2006 3:29 PM To: Maven Users List Subject: RE: skipping tests If you bundle your tests into modules, you can define which modules are dependencies with a profile, and then drive their "run/not run" based on whether or not a profile is defined. -joe -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of EJ Ciramella Sent: Thursday, December 07, 2006 12:26 PM To: Maven Users List Subject: skipping tests So I know about the: -Dmaven.test.skip=true setting, but is there a way to skip packages or modules worth of tests? --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]