RFR: 8305945: (zipfs) Opening a directory to get input stream produces incorrect exception message [v3]

Eirik Bjorsnos duke at openjdk.org
Fri Apr 14 21:41:34 UTC 2023


On Fri, 14 Apr 2023 21:40:17 GMT, Lance Andersen <lancea at openjdk.org> wrote:

>> Please review this trivial change when ZipFS returns the wrong java.nio.file.FileSystemException message due the the parameters being reversed.
>> 
>> I also included a simple junit test as part of the fix.
>> 
>> Mach5 tiers1-3 are clean
>> 
>> Best
>> Lance
>
> Lance Andersen has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Minor wordsmithing of test comment

LGTM. Leaving some minor comments on the test.

test/jdk/jdk/nio/zipfs/ZipFSDirectoryExceptionMessageTest.java line 40:

> 38:  * @test
> 39:  * @bug 8305945
> 40:  * @summary Validate that Zip FS provides the correct exception message

This summary could perhaps be a bit more specific about which condition / message it is testing.

test/jdk/jdk/nio/zipfs/ZipFSDirectoryExceptionMessageTest.java line 56:

> 54:      * Zip file to create
> 55:      */
> 56:     public static final String ZIP_FILE = "directoryExceptionTest.zip";

Maybe ZIP_FILE could be a Path, to avoid Path.of(ZIP_FILE) wrapping later in the test?

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

Marked as reviewed by eirbjo at github.com (no known OpenJDK username).

PR Review: https://git.openjdk.org/jdk/pull/13482#pullrequestreview-1386198889
PR Review Comment: https://git.openjdk.org/jdk/pull/13482#discussion_r1167287569
PR Review Comment: https://git.openjdk.org/jdk/pull/13482#discussion_r1167286862


More information about the nio-dev mailing list