@Test
public void testDeserializer() throws IOException {

  final DataInputStream in = Mockito.mock(DataInputStream.class);
  Mockito.when(in.hasUnReadData()).thenReturn(true);
  Assert.assertTrue(serializer.deserializeKV(in, key, value) > 0);
  Mockito.verify(in, Mockito.times(4)).readInt();
  Mockito.verify(in, Mockito.times(2)).readFully(any(byte[].class),
      anyInt(), anyInt());
}