如何为scalatest-maven-plugin设置PermSize?

时间:2015-08-27 10:08:04

标签: java maven memory jvm scalatest

我们使用scalatest-maven-plugin来运行一些火花测试,默认的烫发大小约为80M,这还不够,所以我们常常得到“OutOfMemoryError:PermGen”。

我试图给它一个更大的尺寸,但没有找到如何配置它

1 个答案:

答案 0 :(得分:2)

您可以使用argLine

中记录的<plugin> <groupId>org.scalatest</groupId> <artifactId>scalatest-maven-plugin</artifactId> <version>1.0</version> <configuration> <reportsDirectory>${project.build.directory}/surefire-reports</reportsDirectory> <junitxml>.</junitxml> <filereports>WDF TestSuite.txt</filereports> <argLine>-XX:MaxPermSize=128m</argLine> </configuration> <executions> <execution> <id>test</id> <goals> <goal>test</goal> </goals> </execution> </executions> </plugin> 配置参数
{% for campaigntype in campaigntypes %}
    {% for campaign in campaigntype.campaign_set.all %}
        {{ campaign.name }} 
    {% endfor %}
{% endfor %}