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 <ja...@gmail.com> on 2007/08/30 07:59:04 UTC
Re: After Ran mvn clean install, I got the FileRenameRouteTest failed on windows box
Great stuff, patch applied!
On 8/29/07, Willem Jiang <wi...@gmail.com> wrote:
> Hi,
>
> I just found an interesting thing. When I run mvn clean install with
> the trunk code on windows box, I got the FileRenameRouteTest failed. But
> when I ran it on Linux or ran the test separately in eclipse , the
> FileRenameRouteTest was passed .
>
> So I digged out the codes. I found the new added asyncProcessor in
> FileConsumer will not call the processStrategy.commit method in the
> whole unit test. That is AsyncCallback never be called in the
> FileRouteTest.
>
> When I changed the AsyncProcessorTypeConverter's process method like the
> below codes,
> the FileConsumer's AsyncCallback was called.
>
> public boolean process(Exchange exchange, AsyncCallback callback) {
> try {
> processor.process(exchange);
> } catch (Throwable e) {
> exchange.setException(e);
> }
> // false means processing of the exchange asynchronously,
> the original code used true parameter
> callback.done(false);
> return true;
> }
>
> And for the FileRenameRouteTest , my suggestion is set the surefire
> plugin's forkMode to be pertest. I just tested it on windows.
> <plugin>
> <artifactId>maven-surefire-plugin</artifactId>
> <configuration>
> <forkMode>pertest</forkMode>
> .....
>
> Willem.
>
>
>
--
James
-------
http://macstrac.blogspot.com/