assertNotNull(serializer);
assertEquals(String.class, serializer.getReturnClass());
assertEquals(FruitCollection.class, serializer.getSourceClass());
assertEquals(3, serializer.getSerializationMixins().size());
JsonToObject deserializer = (JsonToObject) muleContext.getRegistry().lookupObject("jsonToFruitCollection");
assertNotNull(deserializer);
assertEquals(FruitCollection.class, deserializer.getReturnClass());
assertEquals(1, deserializer.getDeserializationMixins().size());
//Test roundTrip
FruitCollection fc = JsonBeanRoundTripTestCase.JSON_OBJECT;
String result = (String)serializer.transform(fc);
assertNotNull(result);
// compare the structure and values but not the attributes' order
ObjectMapper mapper = new ObjectMapper();
JsonNode actualJsonNode = mapper.readTree(result);
JsonNode expectedJsonNode = mapper.readTree(JsonBeanRoundTripTestCase.JSON_STRING);
assertEquals(actualJsonNode, expectedJsonNode);
FruitCollection result2 = (FruitCollection)deserializer.transform(result);
assertNotNull(result2);
assertEquals(fc, result2);
}