camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen" <claus.ib...@gmail.com>
Subject Re: Weird error with expectedBodiesReceived
Date Mon, 01 Dec 2008 09:01:42 GMT
Hi

Do you get a compiler error? Is that what the error is?

We use varargs so you should be able to supply multiple strings
expectedBodisRecieved("hello", "bye", "world");

Or just a single
expectedBodisRecieved("hello");

Could you mess a bit more? Looks weird.

/Claus Ibsen
Apache Camel Committer
Blog: http://davsclaus.blogspot.com/



On Mon, Dec 1, 2008 at 5:51 AM, Sylvester <sylvestersteele@gmail.com> wrote:
> Hi,
> Earlier the following was running just fine. Out of the blue it started
> giving me this error:
> expectedBodiesReceived (List) not applicable to
> expectedBodiesReceived(String). I understand what it means, but:
>
>  1. The examples on the camel website all have strings, so this should
>     not be a problem.
>  2. Why should it stop working just like that? ( I had played around
>     with the pom, could that be it?)
>
> public void testSendingAMessageUsingMulticastReceivesItsOwnExchange() throws
> Exception {
>       MockEndpoint x = getMockEndpoint("mock:x");
>       MockEndpoint y = getMockEndpoint("mock:y");
>       MockEndpoint z = getMockEndpoint("mock:z");
>             x.expectedBodiesReceived("answer");
>       y.expectedBodiesReceived("answer");
>       z.expectedBodiesReceived("answer");
>                   z.expectedMinimumMessageCount(100);
>
>       sendBody();
> //        z.assertIsSatisfied();
>       assertMockEndpointsSatisifed();
>         }
>
>
> pom excerpt:
>
> <properties>
>       <activemq-version>5.1.0</activemq-version>
>       <camel-version>1.4.0</camel-version>
>   </properties>
>
>
> <dependencies>
>       <dependency>
>           <groupId>org.apache.camel</groupId>
>           <artifactId>camel-core</artifactId>
>           <version>${camel-version}</version>
>           <type>test-jar</type>
>           <scope>test</scope>
>       </dependency>
>       <dependency>
>           <groupId>org.apache.camel</groupId>
>           <artifactId>camel-spring</artifactId>
>           <version>${camel-version}</version>
>           <type>test-jar</type>
>           <scope>test</scope>
>       </dependency>
>       <dependency>
>           <groupId>org.apache.camel</groupId>
>           <artifactId>camel-jms</artifactId>
>           <version>${camel-version}</version>
>       </dependency>
>       <dependency>
>           <groupId>org.apache.activemq</groupId>
>           <artifactId>activemq-core</artifactId>
>           <version>${activemq-version}</version>
>       </dependency>
>       <dependency>
>           <groupId>commons-pool</groupId>
>           <artifactId>commons-pool</artifactId>
>           <version>1.3</version>
>       </dependency>
>
>       <dependency>
>           <groupId>javax.xml.bind</groupId>
>           <artifactId>jaxb-api</artifactId>
>           <version>2.0</version>
>       </dependency>
>       <dependency>
>           <groupId>junit</groupId>
>           <artifactId>junit</artifactId>
>           <version>3.8.2</version>
>       </dependency>
>   </dependencies>
>
>

Mime
View raw message