--- old/test/hotspot/jtreg/runtime/appcds/jigsaw/PatchModule/SubClassOfPatchedClass.java 2018-04-09 15:33:25.258576820 -0700 +++ new/test/hotspot/jtreg/runtime/appcds/jigsaw/PatchModule/SubClassOfPatchedClass.java 2018-04-09 15:33:24.983550883 -0700 @@ -88,7 +88,8 @@ "--patch-module=java.naming=" + moduleJar, "-Xlog:class+load", "PatchMain", "javax.naming.Reference", "mypackage.MyReference"); - TestCommon.checkDump(output, "Loading classes to share"); + output.shouldHaveExitValue(1) + .shouldContain("Cannot use the following option when dumping the shared archive: --patch-module"); String classPath = appJar + File.pathSeparator + classDir; System.out.println("classPath: " + classPath); @@ -98,8 +99,6 @@ "--patch-module=java.naming=" + moduleJar, "-Xlog:class+load", "PatchMain", "javax.naming.Reference", "mypackage.MyReference") - .assertNormalExit( - "I pass!", - "MyReference source: file:"); + .assertSilentlyDisabledCDS(0, "MyReference source: file:", "I pass!"); } }