### Question:
JsonMessageMarshaller implements MessageMarshaller { @Override public Message<?> deserialize(String json) throws MessageMarshallerException { try { JSONObject jsonObject = null; Class<?> payloadClass = null; Object payload = null; JSONObject headers = null; JSONObject properties = null; try { jsonObject = new JSONObject(json); } catch (JSONException e) { payloadClass = String.class; payload = json; } if (payloadClass == null) { payloadClass = Class.forName(jsonObject .getString("payloadClazz")); String content = null; if (payloadClass.equals(String.class)) { payload = jsonObject.getString(PAYLOAD_KEY); } else if (payloadClass.isArray()) { content = jsonObject.getJSONArray(PAYLOAD_KEY).toString(); } else if (Number.class.isAssignableFrom(payloadClass)) { payload = jsonObject.get(PAYLOAD_KEY); } else { JSONObject payloadJSONObject = jsonObject .getJSONObject(PAYLOAD_KEY); content = payloadJSONObject.toString(); } if (content != null) { payload = getObjectMapper() .readValue(content, payloadClass); } properties = jsonObject.getJSONObject(PROPERTIES_KEY); headers = jsonObject.getJSONObject(HEADERS_KEY); } MessageBuilder<Object> builder = MessageBuilder .withPayload(payload); if (properties != null) { setProperties(builder, properties); } if (headers != null) { copyHeaders(builder, headers); } return builder.build(); } catch (Exception e) { throw new MessageMarshallerException(e.getMessage(), e.getCause()); } }  @Override String serialize(Message<?> message); @Override Message<?> deserialize(String json);  }### Answer:
@Test public void testSimpleMessage() throws MessageMarshallerException { String simpleMessage = "Hello World"; Message<?> packet = marshaller.deserialize(simpleMessage); assertEquals(simpleMessage, packet.getPayload()); }