On 11/7/2019 5:38 PM, Alexey Semenyuk wrote:

http://cr.openjdk.java.net/~herrick/8233636/webrev.02/test/jdk/tools/jpackage/helpers/jdk/jpackage/test/JavaTool.java.sdiff.html:50
I'd suggest to replace
---
if (name.equals("jpackage"))
---

with more robust
---
if (this == JPACKAGE)
---

http://cr.openjdk.java.net/~herrick/8233636/webrev.02/test/jdk/tools/jpackage/share/jdk/jpackage/tests/BasicTest.java.sdiff.html:
Did you drop JPackageCommand.filterOutput() calls intentionally?

yes - this form of filter just removes the first line (where the other one removes a line starting with some specific strings). When we were printing the warning ourselves,  we would always print it.  Now that we are causing the system to print it by having the "jdk.incubator" package name prefix,  waning is printed when we invoke the tool, but not when we call into it's API (that warning was printed when we compiled the code that was linked to that package).

Anyway - these two tests began failing when we changed package names, because we were filtering out the first line of the output, then not matching.

side note - I noticed a bug in what is printed (in no arg case):

MSG_Help_no_args=Usage: jpackage <mode> <options>\n\
\Use jpackage --help (or -h) for a list of possible options\

there should be no more <mode> in Usage.

(will fix this as part of JDK-8233591 <https://bugs.openjdk.java.net/browse/JDK-8233591>)

/Andy


The rest looks good.

- Alexey

Reply via email to