<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Look for system properties beginning
"test."<br>
<br>
-- Jon<br>
<br>
<br>
On 03/01/2013 10:48 AM, Filipp Zhinkin wrote:<br>
</div>
<blockquote cite="mid:5130F810.50706@oracle.com" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<tt>Hi all, <br>
<br>
It is possible to get TESTVMOPTS value in shell-test, but are
there any ways to get value of that variable in java-test? </tt>
<tt><br>
I've tried to get it simply by System.getenv("TESTVMOPTS"), but
it doesn't work:<br>
<br>
</tt>
<blockquote><tt>/*<br>
</tt><tt> * @test<br>
</tt><tt> * @run main/othervm Test<br>
</tt><tt> */<br>
</tt><tt> public class Test {<br>
</tt><tt> public static void main(String... args) {<br>
</tt><tt> String vmOpts = </tt><tt>System.getenv("TESTVMOPTS");<br>
if (vmOpts == null) {<br>
throw new RuntimeException("Can't get TESTVMOPTS");<br>
} else {<br>
</tt><tt> System.out.println("TESTVMOPTS are: " + vmOpts);<br>
}<br>
</tt><tt> }<br>
</tt><tt> }</tt><br>
</blockquote>
<tt><br>
Thanks, </tt> <tt><br>
Filipp. </tt> </blockquote>
<br>
</body>
</html>