### Question:
CamelotFastMessagesSerializer extends BasicMessagesSerializer { @Override public Object serialize(Object body, ClassLoader classLoader) { if (body != null) { final byte[] bytes = serializeToBytes(body, classLoader); return (bytes != null) ? wrapBytesWithMeta(bytes, body.getClass().getName()) : null; } return null; }  byte[] serializeToBytes(Object object, ClassLoader classLoader); Object deserializeFromBytes(byte[] input, ClassLoader classLoader, Class expectedClass); @Override Object deserialize(Object body, ClassLoader classLoader); @Override Object serialize(Object body, ClassLoader classLoader); static final int MAX_CACHE_SIZE; }### Answer:
@Test public void testSerialize() throws Exception { assertThat(serializer.serialize(null, cl), nullValue()); assertThat(serializer.serialize(null, cl), nullValue()); assertThat(serializer.serialize(new Object(), cl), notNullValue()); verifyThereAndBack("hello"); verifyThereAndBack(95L); verifyThereAndBack(map("hello", "world")); }