test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/ClassPathTests.java
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File
open Cdiff test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/ClassPathTests.java
test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/ClassPathTests.java
Print this page
*** 50,69 ****
--- 50,72 ----
* There is also a 9th test to verify that when --limit-modules is used, a jimage
* class in the archive can be replaced by a classpath class with the
* same name and package.
*/
+ import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.nio.file.Path;
import java.nio.file.Paths;
import jdk.test.lib.Asserts;
import jdk.test.lib.cds.CDSOptions;
import jdk.test.lib.cds.CDSTestUtils;
import jdk.test.lib.process.ProcessTools;
import jdk.test.lib.process.OutputAnalyzer;
+ import jtreg.SkippedException;
+
public class ClassPathTests {
private static final String TEST_SRC = System.getProperty("test.src");
private static final Path SRC_DIR = Paths.get(TEST_SRC, "src");
private static final Path CLASSES_DIR = Paths.get("classes");
*** 90,100 ****
--- 93,111 ----
Method[] methods = tests.getClass().getDeclaredMethods();
int numOfTestMethodsRun = 0;
for (Method m : methods) {
if (m.getName().startsWith("test")) {
System.out.println("About to run test method: " + m.getName());
+ try {
m.invoke(tests);
+ } catch (InvocationTargetException ite) {
+ if (ite.getCause() instanceof SkippedException) {
+ System.out.println("Test PASSED: " + ite.getCause().getMessage());
+ } else {
+ throw ite;
+ }
+ }
numOfTestMethodsRun++;
}
}
Asserts.assertTrue((numOfTestMethodsRun == NUMBER_OF_TEST_CASES),
test/hotspot/jtreg/runtime/appcds/jigsaw/classpathtests/ClassPathTests.java
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File