Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions okhttp/src/main/java/io/grpc/okhttp/OkHttpReadableBuffer.java
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,11 @@ public void readBytes(byte[] dest, int destOffset, int length) {

@Override
public void readBytes(ByteBuffer dest) {
// We are not using it.
throw new UnsupportedOperationException();
try {
buffer.read(dest);
} catch (IOException e) {
throw new RuntimeException(e);
}
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ public void setup() {
}
}

@Override
@Test
public void readToByteBufferShouldSucceed() {
// Not supported.
}

@Override
@Test
public void partialReadToByteBufferShouldSucceed() {
Expand Down