< prev index next >

test/hotspot/jtreg/runtime/modules/PatchModule/PatchModuleDupModule.java

Print this page
@@ -1,7 +1,7 @@
  /*
-  * Copyright (c) 2016, 2023, Oracle and/or its affiliates. All rights reserved.
+  * Copyright (c) 2016, 2026, 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.

@@ -21,11 +21,11 @@
   * questions.
   */
  
  /*
   * @test
-  * @summary Module system initialization exception results if a module is specificed twice to --patch-module.
+  * @summary If a module is specificed twice to --patch-module, it should print an error
   * @requires vm.flagless
   * @modules java.base/jdk.internal.misc
   * @library /test/lib
   * @run driver PatchModuleDupModule
   */

@@ -33,12 +33,12 @@
  import jdk.test.lib.process.OutputAnalyzer;
  import jdk.test.lib.process.ProcessTools;
  
  public class PatchModuleDupModule {
  
-   // The module system initialization should generate an ExceptionInInitializerError
    // if --patch-module is specified with the same module more than once.
+   // The launcher should print an error.
  
    public static void main(String args[]) throws Exception {
      ProcessBuilder pb = ProcessTools.createLimitedTestJavaProcessBuilder(
        "--patch-module=module_one=module_one_dir",
        "--patch-module=module_one=module_one_dir",
< prev index next >