On Thu, 17 Oct 2024 22:56:33 GMT, Brian Burkhalter <b...@openjdk.org> wrote:

>> test/jdk/java/nio/file/Files/InputStreamTest.java line 139:
>> 
>>> 137:             InputStream s = Files.newInputStream(stdin);
>>> 138:             s.available();
>>> 139:         }
>> 
>> I assume you meant to close the input stream.
>> 
>> What about the other methods defined by InputStream that have special 
>> handling in ChannelInputStream? I assume we should add test coverage for 
>> these methods.
>
> I added test coverage for `skip` but not for `readAllBytes` nor `readNBytes`:
> - `readAllBytes` throws before but hangs after the change;
> - `readNBytes` hangs both before and after the change.

I wonder if there is another special file that could be read to EOF to allow 
the methods be tested. Asking because the overrides have a code path we need to 
test.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21508#discussion_r1806067813

Reply via email to