diff --git a/test/jdk/jdk/classfile/CorpusTest.java b/test/jdk/jdk/classfile/CorpusTest.java index 21e275a837d..64db67e6d8e 100644 --- a/test/jdk/jdk/classfile/CorpusTest.java +++ b/test/jdk/jdk/classfile/CorpusTest.java @@ -117,7 +117,7 @@ class CorpusTest { static Path[] corpus() throws IOException, URISyntaxException { splitTableAttributes("testdata/Pattern2.class", "testdata/Pattern2-split.class"); return Stream.of( - Files.walk(JRT.getPath("modules/java.base/java")), + Files.walk(JRT.getPath("modules/java.base/java/util")), Files.walk(JRT.getPath("modules"), 2).filter(p -> p.endsWith("module-info.class")), Files.walk(Paths.get(URI.create(CorpusTest.class.getResource("CorpusTest.class").toString())).getParent())) .flatMap(p -> p) @@ -140,6 +140,7 @@ class CorpusTest { for (Transforms.NoOpTransform m : Transforms.NoOpTransform.values()) { if (m == Transforms.NoOpTransform.ARRAYCOPY || m == Transforms.NoOpTransform.SHARED_3_NO_STACKMAP + || m == Transforms.NoOpTransform.CLASS_REMAPPER || m.name().startsWith("ASM")) continue; @@ -190,12 +191,8 @@ class CorpusTest { .collect(joining("\n")); fail(String.format("Errors in testNullAdapt: %s", msg)); } - } - @ParameterizedTest - @MethodSource("corpus") - void testReadAndTransform(Path path) throws IOException { - byte[] bytes = Files.readAllBytes(path); + // test read and transform var cc = ClassFile.of(); var classModel = cc.parse(bytes); assertEqualsDeep(ClassRecord.ofClassModel(classModel), ClassRecord.ofStreamingElements(classModel),