// we send in a bar string as header which cannot be converted to a number so it should fail
try {
template.requestBodyAndHeader("direct:start", "Hello World", "foo", 555);
fail("Should have thrown an exception");
} catch (CamelExecutionException e) {
NoTypeConversionAvailableException ntae = assertIsInstanceOf(NoTypeConversionAvailableException.class, e.getCause());
assertEquals(Integer.class, ntae.getFromType());
assertEquals(Document.class, ntae.getToType());
assertEquals(555, ntae.getValue());
assertNotNull(ntae.getMessage());
}
assertMockEndpointsSatisfied();
}