org.apache.camel.component.test
Class TestEndpoint
java.lang.Object
org.apache.camel.impl.DefaultEndpoint<Exchange>
org.apache.camel.component.mock.MockEndpoint
org.apache.camel.component.test.TestEndpoint
- All Implemented Interfaces:
- CamelContextAware, Endpoint<Exchange>, Service, BrowsableEndpoint<Exchange>
public class TestEndpoint
- extends MockEndpoint
- implements Service
A Test Endpoint is a
Mock Endpoint for testing but it will
pull all messages from the nested endpoint and use those as expected message body assertions.
- Version:
- $Revision: 655516 $
Method Summary |
protected Object |
getInBody(Exchange exchange)
This method allows us to convert or coerce the expected message body into some other type |
void |
start()
|
void |
stop()
|
Methods inherited from class org.apache.camel.component.mock.MockEndpoint |
addPropertyChangeListener, allMessages, assertEquals, assertExchangeReceived, assertIsNotSatisfied, assertIsSatisfied, assertIsSatisfied, assertIsSatisfied, assertIsSatisfied, assertIsSatisfied, assertMessagesAscending, assertMessagesDescending, assertMessagesSorted, assertNoDuplicates, assertTrue, assertWait, await, await, createConsumer, createProducer, expectedBodiesReceived, expectedBodiesReceived, expectedBodiesReceivedInAnyOrder, expectedBodiesReceivedInAnyOrder, expectedHeaderReceived, expectedMessageCount, expectedMinimumMessageCount, expects, expectsAscending, expectsDescending, expectsMessageCount, expectsNoDuplicates, fail, getExchanges, getExpectedCount, getExpectedMinimumCount, getFailures, getReceivedCounter, getReceivedExchanges, getReporter, getResultWaitTime, getSleepForEmptyTest, isSingleton, message, onExchange, performAssertions, removePropertyChangeListener, reset, resolve, setExpectedMessageCount, setMinimumExpectedMessageCount, setMinimumResultWaitTime, setReporter, setResultWaitTime, setSleepForEmptyTest, waitForCompleteLatch, whenAnyExchangeReceived, whenExchangeReceived |
Methods inherited from class org.apache.camel.impl.DefaultEndpoint |
configureProperties, convertTo, createEndpointUri, createExchange, createExchange, createExchange, createExecutorService, createPollingConsumer, equals, getCamelContext, getComponent, getContext, getEndpointUri, getExchangePattern, getExchangeType, getExecutorService, hashCode, isLenientProperties, setCamelContext, setContext, setEndpointUri, setExchangePattern, setExecutorService, toString |
Methods inherited from interface org.apache.camel.Endpoint |
configureProperties, createExchange, createExchange, createExchange, createPollingConsumer, getCamelContext, getContext, getEndpointUri, isLenientProperties, setCamelContext, setContext |
TestEndpoint
public TestEndpoint(String endpointUri,
Component component,
Endpoint expectedMessageEndpoint)
TestEndpoint
public TestEndpoint(String endpointUri,
Endpoint expectedMessageEndpoint)
start
public void start()
throws Exception
- Specified by:
start
in interface Service
- Throws:
Exception
stop
public void stop()
throws Exception
- Specified by:
stop
in interface Service
- Throws:
Exception
getInBody
protected Object getInBody(Exchange exchange)
- This method allows us to convert or coerce the expected message body into some other type
Copyright © 2009 Apache Software Foundation. All Rights Reserved.