Hi, I want to skip my tests for specific projects which contains integration tests.. I have read alot on the web/forums/maillists etc and found that this is sort of a de-fact way of doing this:
[pom.xml: contained in that separate which only contains these tests]= <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <configuration> <skip>true</skip> </configuration> <executions> <execution> <id>surefire-it</id> <phase>integration-test</phase> <goals> <goal>test</goal> </goals> <configuration> <skip>false</skip> </configuration> </execution> </executions> </plugin> </plugins> </build> The tests are skipped for most commands (compile, test, package etc) which is good. But when i run mvn install, the tests are run. It seems as if "install" matches my "surefire-it" executions, which was not my intention... [INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Building XXXXX JAR [INFO] task-segment: [integration-test] [INFO] ------------------------------------------------------------------------ [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] [INFO] Nothing to compile - all classes are up to date [INFO] [resources:testResources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:testCompile] [INFO] Nothing to compile - all classes are up to date [INFO] [surefire:test] [INFO] Tests are skipped. [INFO] [jar:jar] [INFO] [surefire:test {execution: surefire-it}] [INFO] Surefire report directory: c:\myplace\dev\integrationtest\target\surefire-reports ------------------------------------------------------- T E S T S ------------------------------------------------------- Running xxx.xxx.AdminIntegrationTest Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.047 sec Results : Tests run: 1, Failures: 0, Errors: 0, Skipped: 0 [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 2 seconds [INFO] Finished at: Tue Apr 01 16:30:10 CEST 2008 [INFO] Final Memory: 5M/11M [INFO] ------------------------------------------------------------------------ I only want it to be run if i run "integration-test".. Have any one encountered this before? thanks and regards, -Kristoffer -- View this message in context: http://www.nabble.com/Skip-tests-for-installation-phase-tp16418470s177p16418470.html Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]