RFR: 8361715: (bf) Improve java/nio/Buffer/GetChars.java and migrate to JUnit [v11]

Alan Bateman alanb at openjdk.org
Mon Jul 28 14:20:06 UTC 2025


On Fri, 25 Jul 2025 18:47:21 GMT, Brett Okken <duke at openjdk.org> wrote:

>> junit for CharSequence behavior of CharBuffer covering different CharBuffer implementations in various states (offset, position, limit)
>
> Brett Okken has updated the pull request incrementally with one additional commit since the last revision:
> 
>   code review comments

test/jdk/java/nio/Buffer/CharBufferAsCharSequenceTest.java line 100:

> 98:         populateAndAddCases("LEHeapByteBuffer", ByteBuffer.allocate(SIZE*2).order(ByteOrder.LITTLE_ENDIAN).asCharBuffer(), args);
> 99:         populateAndAddCases("BEDirectByteBuffer", ByteBuffer.allocateDirect(SIZE*2).order(ByteOrder.BIG_ENDIAN).asCharBuffer(), args);
> 100:         populateAndAddCases("LEDirectByteBuffer", ByteBuffer.allocateDirect(SIZE*2).order(ByteOrder.LITTLE_ENDIAN).asCharBuffer(), args);

Having BE or LE at the start of the type name is a bit confusing, would be clear (and more like charset names) to append rather than prepend.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26282#discussion_r2236683766


More information about the nio-dev mailing list