Specifying java options for tests run by surefire

To specify jvm options for a test you can use argLine system property:

http://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#argLine

E.g. to set max perm size to 2 GB you can do:
mvn clean install -DargLine="-XX:MaxPermSize=2g"

Advertisements