camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Frankiboy <>
Subject Test a single Bean with CamelTestSupport ?
Date Thu, 19 Jun 2014 08:12:58 GMT
All i want is to call a Bean class, with a header and body , and check the
body if its correct when it returns.

Her is the bean i try to call: 

public Document enrich(@Headers Map<?,?> requestHeaders, Document doc)
throws TransformerException {

  // There is some more code here...

This is my test class... Byt get error that endpoint is missing... Is there
a simple example somewhere to call a bean ?

public class FilterTest extends CamelTestSupport {   
    String header =
    @Test    public void testSendMatchingMessage() throws Exception {     
        String expectedBody = "<matched/>";      
        template.sendBodyAndHeader(expectedBody, "header", "header");    
    @Override    protected RouteBuilder createRouteBuilder() {    
          return new RouteBuilder() {            public void configure() {      


View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message