test/script/nosecurity/JDK-8050964.js
Print this page
*** 44,55 ****
var nashornJar = new File(System.getProperty("nashorn.jar"));
if (! nashornJar.isAbsolute()) {
nashornJar = new File(".", nashornJar);
}
// run jdep on nashorn.jar - only summary but print profile info
! `jdeps -s -P ${nashornJar.absolutePath}`
// check for "(compact1)" in output from jdep tool
if (! /(compact1)/.test($OUT)) {
fail("non-compact1 dependency: " + $OUT);
}
--- 44,58 ----
var nashornJar = new File(System.getProperty("nashorn.jar"));
if (! nashornJar.isAbsolute()) {
nashornJar = new File(".", nashornJar);
}
+ var javahome = System.getProperty("java.home");
+ var jdepsPath = javahome + "/../bin/jdeps".replaceAll(/\//g, File.separater);
+
// run jdep on nashorn.jar - only summary but print profile info
! `${jdepsPath} -s -P ${nashornJar.absolutePath}`
// check for "(compact1)" in output from jdep tool
if (! /(compact1)/.test($OUT)) {
fail("non-compact1 dependency: " + $OUT);
}