RFR for JDK-8028708. Tests Tests should pass through VM options
Jonathan Gibbons
jonathan.gibbons at oracle.com
Mon Dec 9 08:32:35 PST 2013
On 12/09/2013 08:03 AM, Andrey Nazarov wrote:
> Hi everyone,
>
> I'm fixing following tests.
> tools/javac/api/ToolProvider/HelloWorldTest.java
> tools/javac/api/ToolProvider/ToolProviderTest1.java
> tools/javac/api/ToolProvider/ToolProviderTest2.java
>
> Tests should pass through VM options.
>
> Root cause:
> VM options are not passed to java executed by java programs.
>
> SUGGESTED FIX:
> Add System.getProperty("test.vm.opts","") and
> System.getProperty("test.java.opts","") to invocations of the java cmd
> for *.java tests.
>
> Webrev:
> http://cr.openjdk.java.net/~anazarov/JDK-8028708/webrev.00/
> <http://cr.openjdk.java.net/%7Eanazarov/JDK-8028708/webrev.00/>
>
> --Thanks,
> Andrey
The fix is OK, but in general it is not important to be able to run
javac tests under a variety of externally provided JVM options. Do you
have a particular reason for the fix?
Since you've written the same code 3 times in ToolBox.java, you might
want to use a shared utility method instead.
-- Jon
More information about the compiler-dev
mailing list