@Test
public void testAvailableOperation() {

  when(stream.isReceiveReady()).thenReturn(true);
  scanner = new RowResultScanner<>(stream, TEST_ARRAY);
  assertEquals(1, scanner.available());
  when(stream.isReceiveReady()).thenReturn(false);
  assertEquals(0, scanner.available());
  verify(stream, times(2)).isReceiveReady();
}