You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "James Strachan (JIRA)" <ji...@apache.org> on 2008/02/27 07:55:17 UTC

[jira] Resolved: (CAMEL-327) implement mock testing using a new Endpoint which grabs the expected messages from another endpoint

     [ https://issues.apache.org/activemq/browse/CAMEL-327?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Strachan resolved CAMEL-327.
----------------------------------

    Resolution: Fixed

See the [test endpoint|http://activemq.apache.org/camel/test.html] which pulls messages on startup until there are no more available

> implement mock testing using a new Endpoint which grabs the expected messages from another endpoint
> ---------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-327
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-327
>             Project: Apache Camel
>          Issue Type: New Feature
>            Reporter: James Strachan
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 1.3.0
>
>
> e.g. it'd be nice to be able to write a test case as something like...
> {code}
> from("something").to("mock:file://src/test/data");
> {code}
> Where the mock endpoint is smart enough to spot that its name is a URI - in which case it basically consumes messages from that URI and for each message it receives, it uses that as another assertion on the actual mock endpoint.
> i.e. we can use a directory of expected messages as the assertion statements in a test case.
> We might want to support some kinda XML message payload, so that we can make assertions on what kinda headers and payloads we expect on the messages. Or maybe we just have some kinda transform in between to strip out any headers we don't care about. Something like...
> {code}
> from("something").bean(RemoveSomeHeaders.class).to("mock:file://src/test/data");
> {code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.