RFR: 8325199: (zipfs) jdk/nio/zipfs/TestPosix.java failed 6 sub-tests
Christoph Langer
clanger at openjdk.org
Sun Feb 4 22:26:00 UTC 2024
On Sun, 4 Feb 2024 21:23:39 GMT, Eirik Bjørsnøs <eirbjo at openjdk.org> wrote:
> Please review this PR which fixes an intermittent failure on Windows for the `TestPosix` test.
>
> The recently introduced test `setPermissionsShouldConvertToUnix` fails to close the `FileSystem` returned by `createEmptyZipFile`. The solution is to move this call within the 'try-with-resources' statement, ensuring it gets properly closed.
>
> Besides fixing the underlying file resource management issue, this PR also re-enables this test on Windows.
>
> Since the author failed to realize that the method `createEmptyZipFile` returns an open FileSystem, this PR also suggests that we rename this method to `createEmptyZipFileSystem` in the hope that it will reduce future confusion.
Looks good. Thanks for fixing the test.
-------------
Marked as reviewed by clanger (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/17702#pullrequestreview-1861589938
More information about the nio-dev
mailing list