code_junkie

Is there a way to separate long running (e.g. stress tests) out so they're not run by default in Maven 2?

Nov 12th, 2011
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.69 KB | None | 0 0
  1. <profile>
  2. <id>integrationtest</id>
  3. <build>
  4. <plugins>
  5. <plugin>
  6. <groupId>org.apache.maven.plugins</groupId>
  7. <artifactId>maven-surefire-plugin</artifactId>
  8. <configuration>
  9. <argLine>-client -Xmx896m -XX:MaxPermSize=192m</argLine>
  10. <forkMode>once</forkMode>
  11. <includes>
  12. <include>**/**/*Test.java</include>
  13. <include>**/**/*IntTest.java</include>
  14. </includes>
  15. <excludes>
  16. <exclude>**/**/*SeleniumTest.java</exclude>
  17. </excludes>
  18. </configuration>
  19. </plugin>
  20. </plugins>
  21. </build>
  22. <activation>
  23. <property>
  24. <name>integrationtest</name>
  25. </property>
  26. </activation>
  27. </profile>
  28.  
  29. <plugins>
  30. <plugin>
  31. <groupId>org.codehaus.mojo</groupId>
  32. <artifactId>shitty-maven-plugin</artifactId>
  33. </plugin>
  34. </plugins>
  35.  
  36. <profile>
  37. <id>normal</id>
  38. <build>
  39. <plugins>
  40. <plugin>
  41. <groupId>org.apache.maven.plugins</groupId>
  42. <artifactId>maven-surefire-plugin</artifactId>
  43. <configuration>
  44. <excludes>
  45. <exclude>**/**/*IntTest.java</exclude>
  46. </excludes>
  47. </configuration>
  48. </plugin>
  49. </plugins>
  50. </build>
  51. <activation>
  52. <activeByDefault>true</activeByDefault>
  53. </activation>
  54. </profile>
  55.  
  56. mvn -P integrationtest clean install
Add Comment
Please, Sign In to add comment