8027752: sun/tools/jstatd/TestJstatdExternalRegistry.java: java.lang.SecurityException: attempt to add a Permission to a readonly Permissions object
Reviewed-by: sla, jbachorik
--- a/jdk/test/sun/tools/jstatd/JstatdTest.java Fri Nov 08 08:47:39 2013 +0100
+++ b/jdk/test/sun/tools/jstatd/JstatdTest.java Thu Nov 07 16:55:39 2013 +0100
@@ -291,6 +291,8 @@
launcher.addVMArg("-XX:+UsePerfData");
String testSrc = System.getProperty("test.src");
File policy = new File(testSrc, "all.policy");
+ assertTrue(policy.exists() && policy.isFile(),
+ "Security policy " + policy.getAbsolutePath() + " does not exist or not a file");
launcher.addVMArg("-Djava.security.policy=" + policy.getAbsolutePath());
if (port != null) {
launcher.addToolArg("-p");