diff -r 2c33418a6d57 -r 83b611b88ac8 jdk/test/tools/jlink/plugins/PluginsNegativeTest.java --- a/jdk/test/tools/jlink/plugins/PluginsNegativeTest.java Thu Apr 06 17:01:03 2017 +0000 +++ b/jdk/test/tools/jlink/plugins/PluginsNegativeTest.java Fri Apr 07 08:05:54 2017 +0000 @@ -30,7 +30,6 @@ * jdk.jlink/jdk.tools.jlink.plugin * @run main/othervm PluginsNegativeTest */ -import java.lang.reflect.Layer; import java.util.ArrayList; import java.util.Collections; import java.util.List; @@ -63,7 +62,7 @@ private void testDuplicateBuiltInProviders() { List javaPlugins = new ArrayList<>(); - javaPlugins.addAll(PluginRepository.getPlugins(Layer.boot())); + javaPlugins.addAll(PluginRepository.getPlugins(ModuleLayer.boot())); for (Plugin javaPlugin : javaPlugins) { System.out.println("Registered plugin: " + javaPlugin.getName()); } @@ -72,7 +71,7 @@ try { PluginRepository.registerPlugin(new CustomPlugin(pluginName)); try { - PluginRepository.getPlugin(pluginName, Layer.boot()); + PluginRepository.getPlugin(pluginName, ModuleLayer.boot()); throw new AssertionError("Exception is not thrown for duplicate plugin: " + pluginName); } catch (Exception ignored) { } @@ -83,7 +82,7 @@ } private void testUnknownProvider() { - if (PluginRepository.getPlugin("unknown", Layer.boot()) != null) { + if (PluginRepository.getPlugin("unknown", ModuleLayer.boot()) != null) { throw new AssertionError("Exception expected for unknown plugin name"); } }