jtreg classpath setup inconsistency
Chris Plummer
chris.plummer at oracle.com
Mon Oct 3 15:28:12 UTC 2016
Hello,
Can a jtreg expert please look at
https://bugs.openjdk.java.net/browse/JDK-8167001. I'd like to know why
invoking a jtreg test from the command line is executed differently than
doing so from test/Makefile. This results in different handling of the
classpath passed to the test, and is causing a test to fail as a result.
I have a solution to fix the test (pass "true" as the first argument to
ProcessTools.createJavaProcessBuilder), but I want to better understand
why the classpath isn't consistently set up.
In summary, invoking from the command line will cause the classpath to
be setup be exporting CLASSPATH before running the test. This results in
the classpath being setup for java subprocesses that are created. When
invoking from test/Makefile, the classpath is setup by running with
-classpath. In this case the classpath is not implicitly passed to the
subprocesses, but can be explicitly passed by passing true for the first
argument to ProcessTools.createJavaProcessBuilder (which defaults to
true for hotspot jtreg tests, but false for jdk jtreg tests).
thanks,
Chris
More information about the jtreg-dev
mailing list