8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @modules java.base/jdk.internal.module
27 * @library /test/lib
28 * @build jdk.test.lib.util.ModuleInfoWriter
29 * @run testng ClassFileVersionsTest
30 * @summary Test parsing of module-info.class with different class file versions
31 */
32
33 import java.lang.classfile.ClassFile;
34 import java.lang.module.InvalidModuleDescriptorException;
35 import java.lang.module.ModuleDescriptor;
36 import java.lang.module.ModuleDescriptor.Requires.Modifier;
37 import java.nio.ByteBuffer;
38 import java.util.ArrayList;
39 import java.util.List;
40 import java.util.Set;
41
42 import static java.lang.module.ModuleDescriptor.Requires.Modifier.*;
43
44 import jdk.test.lib.util.ModuleInfoWriter;
45
46 import org.testng.annotations.DataProvider;
47 import org.testng.annotations.Test;
48 import static org.testng.Assert.*;
|
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @modules java.base/jdk.internal.module
27 * @library /test/lib
28 * @run testng ClassFileVersionsTest
29 * @summary Test parsing of module-info.class with different class file versions
30 */
31
32 import java.lang.classfile.ClassFile;
33 import java.lang.module.InvalidModuleDescriptorException;
34 import java.lang.module.ModuleDescriptor;
35 import java.lang.module.ModuleDescriptor.Requires.Modifier;
36 import java.nio.ByteBuffer;
37 import java.util.ArrayList;
38 import java.util.List;
39 import java.util.Set;
40
41 import static java.lang.module.ModuleDescriptor.Requires.Modifier.*;
42
43 import jdk.test.lib.util.ModuleInfoWriter;
44
45 import org.testng.annotations.DataProvider;
46 import org.testng.annotations.Test;
47 import static org.testng.Assert.*;
|