8173396: Error message issue with jar tool API validator
authorsherman
Sat, 28 Jan 2017 20:51:28 -0800
changeset 43331 0bcbff9e43aa
parent 43330 6aa5f2938b75
child 43332 88688213d2e3
8173396: Error message issue with jar tool API validator Reviewed-by: psandoz, mchung
jdk/src/jdk.jartool/share/classes/sun/tools/jar/Validator.java
jdk/test/ProblemList.txt
jdk/test/tools/jar/multiRelease/ApiValidatorTest.java
--- a/jdk/src/jdk.jartool/share/classes/sun/tools/jar/Validator.java	Fri Jan 27 13:10:27 2017 -0800
+++ b/jdk/src/jdk.jartool/share/classes/sun/tools/jar/Validator.java	Sat Jan 28 20:51:28 2017 -0800
@@ -356,7 +356,7 @@
                 this.md = md;
             } else {
                 if (!root.name().equals(md.name())) {
-                    error(getMsg("error.versioned.info.name.notequal"));
+                    error(getMsg("error.validator.info.name.notequal"));
                     isValid = false;
                 }
                 if (!root.requires().equals(md.requires())) {
@@ -365,10 +365,10 @@
                         if (rootRequires.contains(r))
                             continue;
                         if (r.modifiers().contains(Requires.Modifier.TRANSITIVE)) {
-                            error(getMsg("error.versioned.info.requires.transitive"));
+                            error(getMsg("error.validator.info.requires.transitive"));
                             isValid = false;
                         } else if (!isPlatformModule(r.name())) {
-                            error(getMsg("error.versioned.info.requires.added"));
+                            error(getMsg("error.validator.info.requires.added"));
                             isValid = false;
                         }
                     }
@@ -377,21 +377,21 @@
                         if (mdRequires.contains(r))
                             continue;
                         if (!isPlatformModule(r.name())) {
-                            error(getMsg("error.versioned.info.requires.dropped"));
+                            error(getMsg("error.validator.info.requires.dropped"));
                             isValid = false;
                         }
                     }
                 }
                 if (!root.exports().equals(md.exports())) {
-                    error(getMsg("error.versioned.info.exports.notequal"));
+                    error(getMsg("error.validator.info.exports.notequal"));
                     isValid = false;
                 }
                 if (!root.opens().equals(md.opens())) {
-                    error(getMsg("error.versioned.info.opens.notequal"));
+                    error(getMsg("error.validator.info.opens.notequal"));
                     isValid = false;
                 }
                 if (!root.provides().equals(md.provides())) {
-                    error(getMsg("error.versioned.info.provides.notequal"));
+                    error(getMsg("error.validator.info.provides.notequal"));
                     isValid = false;
                 }
                 if (!root.mainClass().equals(md.mainClass())) {
--- a/jdk/test/ProblemList.txt	Fri Jan 27 13:10:27 2017 -0800
+++ b/jdk/test/ProblemList.txt	Sat Jan 28 20:51:28 2017 -0800
@@ -262,8 +262,6 @@
 
 tools/jlink/multireleasejar/JLinkMultiReleaseJarTest.java       8169971 windows-x64
 
-tools/jar/multiRelease/ApiValidatorTest.java                    8173396 generic-all
-
 ############################################################################
 
 # jdk_jdi
--- a/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java	Fri Jan 27 13:10:27 2017 -0800
+++ b/jdk/test/tools/jar/multiRelease/ApiValidatorTest.java	Sat Jan 28 20:51:28 2017 -0800
@@ -31,7 +31,7 @@
  * @build jdk.test.lib.JDKToolFinder jdk.test.lib.Utils jdk.test.lib.process.*
  * @build jdk.testlibrary.FileUtils
  * @build MRTestBase
- * @run testng ApiValidatorTest
+ * @run testng/timeout=1200 ApiValidatorTest
  */
 
 import jdk.test.lib.process.OutputAnalyzer;