protected AbstractTransformer getAndTestEndpointTransformer(String endpointName, Class clazz) throws MuleException
{
assertTrue(AbstractTransformer.class.isAssignableFrom(clazz));
assertEquals(1, muleContext.getEndpointFactory().getInboundEndpoint(endpointName).getTransformers().size());
AbstractTransformer transformer= (AbstractTransformer) muleContext.getEndpointFactory().getInboundEndpoint(endpointName).getTransformers().get(0);
assertNotNull(transformer);
assertTrue(clazz.isAssignableFrom(transformer.getClass()));
return transformer;
}