8227609: (fs) Files.newInputStream(...).skip(n) should allow skipping beyond file size

Lance Andersen lance.andersen at oracle.com
Thu Jul 25 21:04:55 UTC 2019


Hi Brian,

This this looks good.

Given you use TestUtil.removall after the test runs, do you need the finally block to the delete the file within the test?


HTH

Best
Lance
> On Jul 25, 2019, at 4:46 PM, Brian Burkhalter <brian.burkhalter at oracle.com> wrote:
> 
> 
>> On Jul 25, 2019, at 12:58 PM, Alan Bateman <Alan.Bateman at oracle.com <mailto:Alan.Bateman at oracle.com>> wrote:
>> 
>> On 25/07/2019 19:14, Brian Burkhalter wrote:
>>> 
>>> Updated as suggested; test modified accordingly.
>>> 
>>> http://cr.openjdk.java.net/~bpb/8227609/webrev.01/ <http://cr.openjdk.java.net/~bpb/8227609/webrev.01/>
>>> 
>>> 
>> This looks okay.
>> 
>> Can the test be expanded to include cases where the result differs to the input, e.g. skip(-<pos>*2) should return -<pos>, skip(Long.MIN_VALUE) return should -<pos>, etc.
> 
> Some new cases added: http://cr.openjdk.java.net/~bpb/8227609/webrev.02/ <http://cr.openjdk.java.net/~bpb/8227609/webrev.02/>.
> 
> Thanks,
> 
> Brian

 <http://oracle.com/us/design/oracle-email-sig-198324.gif>
 <http://oracle.com/us/design/oracle-email-sig-198324.gif> <http://oracle.com/us/design/oracle-email-sig-198324.gif>
 <http://oracle.com/us/design/oracle-email-sig-198324.gif>Lance Andersen| Principal Member of Technical Staff | +1.781.442.2037
Oracle Java Engineering 
1 Network Drive 
Burlington, MA 01803
Lance.Andersen at oracle.com <mailto:Lance.Andersen at oracle.com>



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/nio-dev/attachments/20190725/e6ba085c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: oracle_sig_logo.gif
Type: image/gif
Size: 658 bytes
Desc: not available
URL: <https://mail.openjdk.java.net/pipermail/nio-dev/attachments/20190725/e6ba085c/oracle_sig_logo.gif>


More information about the nio-dev mailing list