### Question:
CloudEventDeserializer implements Deserializer<CloudEvent> { @Override public CloudEvent deserialize(String topic, byte[] data) { throw new UnsupportedOperationException("CloudEventDeserializer supports only the signature deserialize(String, Headers, byte[])"); }  @Override CloudEvent deserialize(String topic, byte[] data); @Override CloudEvent deserialize(String topic, Headers headers, byte[] data);  }### Answer:
@Test public void deserializerShouldWork() { String topic = "test"; CloudEvent inEvent = Data.V1_WITH_JSON_DATA; CloudEventDeserializer deserializer = new CloudEventDeserializer(); ProducerRecord<Void, byte[]> inRecord = KafkaMessageFactory .createWriter(topic) .writeBinary(inEvent); CloudEvent outEvent = deserializer.deserialize(topic, inRecord.headers(), inRecord.value()); assertThat(outEvent) .isEqualTo(inEvent); }