changeset 4293:5be378ebc530

Rename test automatic modules not to use digits
author mchung
date Sat, 10 Sep 2016 15:57:20 -0700
parents 9cdc06f40dee
children 78d769801dfa
files test/tools/jdeps/modules/CheckModuleTest.java test/tools/jdeps/modules/InverseDeps.java test/tools/jdeps/modules/TransitiveDeps.java test/tools/jdeps/modules/src/m4/module-info.java test/tools/jdeps/modules/src/m6/module-info.java test/tools/jdeps/modules/src/m6/p6/indirect/UnsafeRef.java test/tools/jdeps/modules/src/m6/p6/safe/Lib.java test/tools/jdeps/modules/src/m7/module-info.java test/tools/jdeps/modules/src/m7/p7/Main.java test/tools/jdeps/modules/src/mVI/module-info.java test/tools/jdeps/modules/src/mVI/p6/indirect/UnsafeRef.java test/tools/jdeps/modules/src/mVI/p6/safe/Lib.java test/tools/jdeps/modules/src/mVII/module-info.java test/tools/jdeps/modules/src/mVII/p7/Main.java
diffstat 14 files changed, 198 insertions(+), 198 deletions(-) [+]
line wrap: on
line diff
--- a/test/tools/jdeps/modules/CheckModuleTest.java	Fri Sep 09 12:46:15 2016 +0200
+++ b/test/tools/jdeps/modules/CheckModuleTest.java	Sat Sep 10 15:57:20 2016 -0700
@@ -54,7 +54,7 @@
 
     // m4 and m5 are analyzed.  Others are compiled to make sure they are present
     // on the module path for analysis
-    private static final Set<String> modules = Set.of("unsafe", "m4", "m5", "m6", "m7", "m8");
+    private static final Set<String> modules = Set.of("unsafe", "m4", "m5", "mVI", "mVII", "m8");
 
     private static final String JAVA_BASE = "java.base";
 
@@ -103,7 +103,7 @@
                             .requiresTransitive("java.compiler")
                             .requires("java.logging")
                             // unnused exports
-                            .exports("p4.internal", Set.of("m6", "m7")),
+                            .exports("p4.internal", Set.of("mVI", "mVII")),
                         // suggested version
                         new ModuleMetaData("m4")
                             .requires("java.compiler"),
--- a/test/tools/jdeps/modules/InverseDeps.java	Fri Sep 09 12:46:15 2016 +0200
+++ b/test/tools/jdeps/modules/InverseDeps.java	Sat Sep 10 15:57:20 2016 -0700
@@ -61,7 +61,7 @@
     private static final Path LIBS_DIR = Paths.get("libs");
 
     private static final Set<String> modules = new LinkedHashSet(
-        List.of("unsafe", "m4", "m5", "m6", "m7")
+        List.of("unsafe", "m4", "m5", "mVI", "mVII")
     );
 
     /**
@@ -108,8 +108,8 @@
                 }
             },
             { "jdk.unsupported", new String[][] {
-                    new String[] {"jdk.unsupported", "unsafe", "m6", "m7"},
-                    new String[] {"jdk.unsupported", "unsafe", "m7"}
+                    new String[] {"jdk.unsupported", "unsafe", "mVI", "mVII"},
+                    new String[] {"jdk.unsupported", "unsafe", "mVII"}
                 }
             },
         };
@@ -155,8 +155,8 @@
                     }
             },
             { "sun.misc", new String[][] {
-                        new String[] {"jdk.unsupported", "unsafe", "m6", "m7"},
-                        new String[] {"jdk.unsupported", "unsafe", "m7"}
+                        new String[] {"jdk.unsupported", "unsafe", "mVI", "mVII"},
+                        new String[] {"jdk.unsupported", "unsafe", "mVII"}
                     }
             }
         };
@@ -180,13 +180,13 @@
         return new Object[][] {
             // -regex and result
             { "org.safe.Lib", new String[][] {
-                    new String[] { "unsafe", "m7"},
-                    new String[] { "unsafe", "m6", "m7"},
+                    new String[] { "unsafe", "mVII"},
+                    new String[] { "unsafe", "mVI", "mVII"},
                 }
             },
             { "java.util.logging.*|org.safe.Lib", new String[][] {
-                    new String[] { "unsafe", "m7"},
-                    new String[] { "unsafe", "m6", "m7"},
+                    new String[] { "unsafe", "mVII"},
+                    new String[] { "unsafe", "mVI", "mVII"},
                     new String[] { "java.logging", "m5"},
                 }
             }
@@ -212,18 +212,18 @@
         return new Object[][] {
             // -regex and result
             { "sun.misc.Unsafe", new String[][] {
-                    new String[] {"jdk.unsupported", "unsafe.jar", "m6.jar", "m7.jar"},
-                    new String[] {"jdk.unsupported", "unsafe.jar", "m7.jar"}
+                    new String[] {"jdk.unsupported", "unsafe.jar", "mVI.jar", "mVII.jar"},
+                    new String[] {"jdk.unsupported", "unsafe.jar", "mVII.jar"}
                 }
             },
             { "org.safe.Lib", new String[][] {
-                    new String[] { "unsafe.jar", "m7.jar"},
-                    new String[] { "unsafe.jar", "m6.jar", "m7.jar"},
+                    new String[] { "unsafe.jar", "mVII.jar"},
+                    new String[] { "unsafe.jar", "mVI.jar", "mVII.jar"},
                 }
             },
             { "java.util.logging.*|org.safe.Lib", new String[][] {
-                    new String[] { "unsafe.jar", "m7.jar"},
-                    new String[] { "unsafe.jar", "m6.jar", "m7.jar"},
+                    new String[] { "unsafe.jar", "mVII.jar"},
+                    new String[] { "unsafe.jar", "mVI.jar", "mVII.jar"},
                     new String[] { "java.logging", "m5.jar"},
                 }
             }
@@ -234,11 +234,11 @@
     public void testClassPath(String name, String[][] expected) throws Exception {
         // -classpath
         String cpath = modules.stream()
-            .filter(mn -> !mn.equals("m7"))
+            .filter(mn -> !mn.equals("mVII"))
             .map(mn -> LIBS_DIR.resolve(mn + ".jar").toString())
             .collect(Collectors.joining(File.pathSeparator));
 
-        Path jarfile = LIBS_DIR.resolve("m7.jar");
+        Path jarfile = LIBS_DIR.resolve("mVII.jar");
 
         String cmd1 = String.format("jdeps -inverse -classpath %s -regex %s %s%n",
             cpath, name, jarfile);
--- a/test/tools/jdeps/modules/TransitiveDeps.java	Fri Sep 09 12:46:15 2016 +0200
+++ b/test/tools/jdeps/modules/TransitiveDeps.java	Sat Sep 10 15:57:20 2016 -0700
@@ -58,7 +58,7 @@
     private static final Path LIBS_DIR = Paths.get("libs");
 
     // the names of the modules in this test
-    private static String[] modules = new String[] {"unsafe", "m6", "m7"};
+    private static String[] modules = new String[] {"unsafe", "mVI", "mVII"};
     /**
      * Compiles all modules used by the test
      */
@@ -86,15 +86,15 @@
     @DataProvider(name = "modules")
     public Object[][] expected1() {
         return new Object[][]{
-            { "m7",
-               List.of(new ModuleMetaData("m7")
-                            .requires("m6")
+            { "mVII",
+               List.of(new ModuleMetaData("mVII")
+                            .requires("mVI")
                             .requires("unsafe")
                             .reference("p7.Main", "java.lang.Object", "java.base")
                             .reference("p7.Main", "java.lang.String", "java.base")
                             .reference("p7.Main", "org.safe.Lib", "unsafe")
-                            .reference("p7.Main", "p6.safe.Lib", "m6"),
-                        new ModuleMetaData("m6")
+                            .reference("p7.Main", "p6.safe.Lib", "mVI"),
+                        new ModuleMetaData("mVI")
                             .requires("unsafe")
                             .reference("p6.indirect.UnsafeRef", "java.lang.Object", "java.base")
                             .reference("p6.indirect.UnsafeRef", "org.unsafe.UseUnsafe ", "unsafe")
@@ -121,7 +121,7 @@
 
     @Test(dataProvider = "modules")
     public void testModulePath(String name, List<ModuleMetaData> data) throws IOException {
-        Set<String> roots = Set.of("m6", "unsafe");
+        Set<String> roots = Set.of("mVI", "unsafe");
 
         String cmd1 = String.format("jdeps --module-path %s --add-modules %s -m %s%n", MODS_DIR,
             roots.stream().collect(Collectors.joining(",")), name);
@@ -152,13 +152,13 @@
     @DataProvider(name = "jars")
     public Object[][] expected2() {
         return new Object[][]{
-            { "m7", List.of(new ModuleMetaData("m7.jar")
-                                .requires("m6.jar")
+            { "mVII", List.of(new ModuleMetaData("mVII.jar")
+                                .requires("mVI.jar")
                                 .requires("unsafe.jar")
                                 .reference("p7.Main", "java.lang.Object", "java.base")
                                 .reference("p7.Main", "java.lang.String", "java.base")
                                 .reference("p7.Main", "org.safe.Lib", "unsafe.jar")
-                                .reference("p7.Main", "p6.safe.Lib", "m6.jar"))
+                                .reference("p7.Main", "p6.safe.Lib", "mVI.jar"))
             },
         };
     }
@@ -185,15 +185,15 @@
     @DataProvider(name = "compileTimeView")
     public Object[][] expected3() {
         return new Object[][] {
-            {"m7",
-             List.of(new ModuleMetaData("m7.jar")
-                        .requires("m6.jar")
+            {"mVII",
+             List.of(new ModuleMetaData("mVII.jar")
+                        .requires("mVI.jar")
                         .requires("unsafe.jar")
                         .reference("p7.Main", "java.lang.Object", "java.base")
                         .reference("p7.Main", "java.lang.String", "java.base")
                         .reference("p7.Main", "org.safe.Lib", "unsafe.jar")
-                        .reference("p7.Main", "p6.safe.Lib", "m6.jar"),
-                    new ModuleMetaData("m6.jar")
+                        .reference("p7.Main", "p6.safe.Lib", "mVI.jar"),
+                    new ModuleMetaData("mVI.jar")
                         .requires("unsafe.jar")
                         .reference("p6.indirect.UnsafeRef", "java.lang.Object", "java.base")
                         .reference("p6.indirect.UnsafeRef", "org.unsafe.UseUnsafe ", "unsafe.jar")
@@ -240,15 +240,15 @@
     @DataProvider(name = "recursiveDeps")
     public Object[][] expected4() {
         return new Object[][] {
-            {"m7",
-                List.of(new ModuleMetaData("m7.jar")
-                        .requires("m6.jar")
+            {"mVII",
+                List.of(new ModuleMetaData("mVII.jar")
+                        .requires("mVI.jar")
                         .requires("unsafe.jar")
                         .reference("p7.Main", "java.lang.Object", "java.base")
                         .reference("p7.Main", "java.lang.String", "java.base")
                         .reference("p7.Main", "org.safe.Lib", "unsafe.jar")
-                        .reference("p7.Main", "p6.safe.Lib", "m6.jar"),
-                    new ModuleMetaData("m6.jar")
+                        .reference("p7.Main", "p6.safe.Lib", "mVI.jar"),
+                    new ModuleMetaData("mVI.jar")
                         .requires("unsafe.jar")
                         .reference("p6.safe.Lib", "java.io.PrintStream", "java.base")
                         .reference("p6.safe.Lib", "java.lang.Class", "java.base")
--- a/test/tools/jdeps/modules/src/m4/module-info.java	Fri Sep 09 12:46:15 2016 +0200
+++ b/test/tools/jdeps/modules/src/m4/module-info.java	Sat Sep 10 15:57:20 2016 -0700
@@ -31,5 +31,5 @@
     exports p4;
 
     // unuused qualified exports
-    exports p4.internal to m6,m7;
+    exports p4.internal to mVI,mVII;
 }
--- a/test/tools/jdeps/modules/src/m6/module-info.java	Fri Sep 09 12:46:15 2016 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-module m6 {
-    requires unsafe;
-
-    // no dependency on sun.misc.Unsafe directly or indirectly
-    exports p6.safe;
-
-    // direct dependency on org.unsafe
-    // hence indirect dependency on sun.misc.Unsafe
-    exports p6.indirect;
-}
--- a/test/tools/jdeps/modules/src/m6/p6/indirect/UnsafeRef.java	Fri Sep 09 12:46:15 2016 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,31 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package p6.indirect;
-
-// indirectly depend on sun.misc.Unsafe
-public class UnsafeRef {
-     public static org.unsafe.UseUnsafe get() {
-         return new org.unsafe.UseUnsafe();
-     }
-}
--- a/test/tools/jdeps/modules/src/m6/p6/safe/Lib.java	Fri Sep 09 12:46:15 2016 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package p6.safe;
-
-// no direct or indirect dependency on sun.misc.Unsafe
-public class Lib {
-    public static void doit() {
-        System.out.println(Lib.class.getName());
-        org.safe.Lib.doit();
-    }
-}
--- a/test/tools/jdeps/modules/src/m7/module-info.java	Fri Sep 09 12:46:15 2016 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-module m7 {
-    // only use classes that have no direct or indirect dependency
-    // to sun.misc.Unsafe
-    requires unsafe;
-    requires m6;
-}
--- a/test/tools/jdeps/modules/src/m7/p7/Main.java	Fri Sep 09 12:46:15 2016 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This code is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package p7;
-
-// Only use classes in unsafe and m6 modules with no
-// direct or indirect dependency on sun.misc.Unsafe
-public class Main {
-    public static void main(String... args) {
-        p6.safe.Lib.doit();
-        org.safe.Lib.doit();
-    }
-}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/modules/src/mVI/module-info.java	Sat Sep 10 15:57:20 2016 -0700
@@ -0,0 +1,33 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+module mVI {
+    requires unsafe;
+
+    // no dependency on sun.misc.Unsafe directly or indirectly
+    exports p6.safe;
+
+    // direct dependency on org.unsafe
+    // hence indirect dependency on sun.misc.Unsafe
+    exports p6.indirect;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/modules/src/mVI/p6/indirect/UnsafeRef.java	Sat Sep 10 15:57:20 2016 -0700
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package p6.indirect;
+
+// indirectly depend on sun.misc.Unsafe
+public class UnsafeRef {
+     public static org.unsafe.UseUnsafe get() {
+         return new org.unsafe.UseUnsafe();
+     }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/modules/src/mVI/p6/safe/Lib.java	Sat Sep 10 15:57:20 2016 -0700
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package p6.safe;
+
+// no direct or indirect dependency on sun.misc.Unsafe
+public class Lib {
+    public static void doit() {
+        System.out.println(Lib.class.getName());
+        org.safe.Lib.doit();
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/modules/src/mVII/module-info.java	Sat Sep 10 15:57:20 2016 -0700
@@ -0,0 +1,29 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+module mVII {
+    // only use classes that have no direct or indirect dependency
+    // to sun.misc.Unsafe
+    requires unsafe;
+    requires mVI;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/tools/jdeps/modules/src/mVII/p7/Main.java	Sat Sep 10 15:57:20 2016 -0700
@@ -0,0 +1,33 @@
+/*
+ * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package p7;
+
+// Only use classes in unsafe and mVI modules with no
+// direct or indirect dependency on sun.misc.Unsafe
+public class Main {
+    public static void main(String... args) {
+        p6.safe.Lib.doit();
+        org.safe.Lib.doit();
+    }
+}