PostgreSQLDateBinaryProtocolValue implements PostgreSQLBinaryProtocolValue { @Override public Object read(final PostgreSQLPacketPayload payload) { return payload.readInt8(); }  @Override int getColumnLength(final Object value); @Override Object read(final PostgreSQLPacketPayload payload); @Override void write(final PostgreSQLPacketPayload payload, final Object value);  }
@Test public void assertRead() { when(payload.readInt8()).thenReturn(1L); assertThat(new PostgreSQLDateBinaryProtocolValue().read(payload), is(1L)); }