RFR: 8354724: Methods in java.io.Reader to read all characters and all lines [v26]

Brian Burkhalter bpb at openjdk.org
Wed May 28 15:27:04 UTC 2025


On Wed, 28 May 2025 14:23:07 GMT, Jaikiran Pai <jpai at openjdk.org> wrote:

>> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   8354724: "input reader specific" -> "reader specific"
>
> test/jdk/java/io/Reader/ReadAll.java line 54:
> 
>> 52: public class ReadAll {
>> 53:     private static final String PHRASE =
>> 54:         "Ange plein de gaieté, connaissez-vous l'angoisse";
> 
> Would it be useful to have this (or some other) phrase contain some newline characters and also some whitespaces between a pair of newline characters? That then can exercise the case where the input being read by a `Reader` would consist of empty lines and lines with just whitespace characters. The way the inputs lines are constructed in `setup()`, it's possible that even in current form that scenario might get exercised but it's hard to be sure given the `Random` nature of that content generation.

Thanks for the suggestion. I was thinking of another enhancement of the test anyway and can include this idea later in another request.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24728#discussion_r2112185060


More information about the core-libs-dev mailing list