RFR: 8364213: (bf) Improve java/nio/Buffer/CharBufferAsCharSequenceTest test comments [v5]
Brian Burkhalter
bpb at openjdk.org
Fri Aug 1 16:41:56 UTC 2025
On Fri, 1 Aug 2025 15:18:06 GMT, Roger Riggs <rriggs at openjdk.org> wrote:
>>> Which cases would you remove?
>>
>> All of these:
>> https://github.com/openjdk/jdk/blob/master/test/jdk/java/nio/Buffer/CharBufferAsCharSequenceTest.java#L108-L182
>>
>> As I walked through documenting what they cover, and then worked on breaking them out into smaller methods, they are just exercising the different types, at different ranges and offsets. I do not see a single scenario the static tests are covering which the dynamic/random tests do not. There are actually more combos covered with the random tests.
>
> Looks fine to remove those as duplicates.
> I do not see a single scenario the static tests are covering which the dynamic/random tests do not. There are actually more combos covered with the random tests.
I have observed this situation before elsewhere. Although random tests can be irritating and sometimes tricky to get right, I think in the end the coverage is better. And with the `RandomFactory` seed available, the results are reproducible.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26512#discussion_r2248410226
More information about the nio-dev
mailing list