我正在指定 jvm 参数,因为我正在退出堆空间异常,所以只是为了避免我在我的 ant 目标中指定以下参数,如下所示。
<junit
printsummary="true"
fork="yes"
haltonfailure="false"
failureproperty="junitsFailed"
errorProperty="junitsFailed"
>
<jvmarg value=" -Xmx1024m -Duser.timezone=GMT0"/>
</junit>
但下面我得到以下异常..
that is the invalid parameters are specified
最佳答案
使用多个 <jvmarg>
元素:
<junit printsummary="true" fork="yes" haltonfailure="false" failureproperty="junitsFailed" errorProperty="junitsFailed">
<jvmarg value="-Xmx1024m"/>
<jvmarg value="-Duser.timezone=GMT0"/>
</junit>
关于java - 在 ant 任务中指定 jvm 参数,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25039864/