On Tue, 28 Apr 2026 01:25:55 GMT, Alexander Matveev <[email protected]> 
wrote:

>> Alexey Semenyuk has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Fix review findings
>
> test/jdk/tools/jpackage/junit/share/jdk.jpackage/jdk/jpackage/internal/cli/MainTest.java
>  line 200:
> 
>> 198:                         
>> I18N.format("error.parameter-not-empty-directory", invalidTempValue, 
>> "--temp")),
>> 199:                 // Silent failure.
>> 200:                 build().args("--verbose", "", "--temp", 
>> invalidTempValue).expectErrorExitCode(),
> 
> Confused about these two test cases. I tried both manually via command line 
> and I am getting error printed that `--temp` directory not empty. Why "Silent 
> failure" does not cover it?

> mkdir foo/bar

> ./jdk-27/bin/jpackage --verbose --temp foo
Error: The value "foo" provided for parameter --temp is not an empty directory 
or non existent path
> echo $?
1

> ./jdk-27/bin/jpackage --verbose "" --temp foo
> echo $?
1


`--verbose` and `--verbose ""` are interpreted differently. The first one 
(without the argument) is equivalent to `--verbose errors,warnings`, and the 
second one (empty string argument) means logging is completely disabled, 
jpackage prints nothing to the console.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/29515#discussion_r3157340858

Reply via email to