@Test
public void shouldHandleBlob() {

  Codec<ByteBuffer> blobCodec = mapper.codecFor(primitive(BLOB));
  assertThat(blobCodec).isSameAs(mapper.blob);
  encodeAndDecode(blobCodec, Bytes.fromHexString("0x"), "0x");
  encodeAndDecode(blobCodec, Bytes.fromHexString("0x742f7e"), "0x742f7e");
  encodeAndDecode(blobCodec, null, null);
  ByteBuffer buf = Bytes.fromHexString("0x8679FE");
  encodeObjectAndDecode(blobCodec, null, null, null);
  encodeObjectAndDecode(blobCodec, "0x8679FE", "0x8679fe", buf);
  encodeObjectAndDecode(blobCodec, buf, "0x8679fe", buf);
  encodeObjectAndDecode(blobCodec, Optional.of(12), null, null);
}