test/hotspot/jtreg/runtime/modules/AccessCheck/ExpQualToM1PrivateMethodIAE.java
changeset 50816 a73848f8d0ad
parent 50761 cb07f4b539fc
child 51016 a926b7737d3b
--- a/test/hotspot/jtreg/runtime/modules/AccessCheck/ExpQualToM1PrivateMethodIAE.java	Wed Jun 27 12:46:15 2018 +0200
+++ b/test/hotspot/jtreg/runtime/modules/AccessCheck/ExpQualToM1PrivateMethodIAE.java	Wed Jun 27 09:52:23 2018 +0200
@@ -103,9 +103,10 @@
             String message = e.getMessage();
             System.out.println(e.toString());
             // java.lang.IllegalAccessError:
-            //   tried to access method p2.c2.method2()V from class p1.c1 (p2.c2 is in module m2x of loader
+            //   tried to access private method p2.c2.method2()V from class p1.c1 (p2.c2 is in module m2x of loader
             //   myloaders.MySameClassLoader @<id>; p1.c1 is in module m1x of loader myloaders.MySameClassLoader @<id>)
-            if (!message.contains("class p1.c1 tried to access method p2.c2.method2()V (p1.c1 is in module m1x of loader myloaders.MySameClassLoader @") ||
+            if (!message.contains("class p1.c1 tried to access private method p2.c2.method2()V " +
+                                  "(p1.c1 is in module m1x of loader myloaders.MySameClassLoader @") ||
                 !message.contains("; p2.c2 is in module m2x of loader myloaders.MySameClassLoader @")) {
               throw new RuntimeException("Test Failed, an IAE was thrown with the wrong message: " + e.toString());
             }