@Test
public void testJsonStreamCodec() throws Exception
{

  Map<Class<?>, Class<? extends StringCodec<?>>> codecs = new HashMap<>();
  codecs.put(InnerProperty.class, PojoStringCodec.class);
  JsonStreamCodec jsc = new JsonStreamCodec(codecs);
  PojoClass obj = new PojoClass();
  String s = jsc.toByteArray(obj).stringValue();
  JSONObject json = new JSONObject(s);
  Assert.assertEquals("xyz", json.getString("s"));
  Assert.assertEquals("bar:hello world", json.getString("x"));
}