camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Babak Vahdat <>
Subject About false-positive Test inside Camel source!
Date Tue, 14 Feb 2012 17:38:36 GMT

Today there was a question on the user forum [1] where I applied a patch
regarding it, however my concern by this post is not the issue user suffered
from but the unit-test [2] which does behave false-positive!

If at the line 147 you would change:

          assertEquals(TEXT, result);

          assertEquals(null, result);

The test would *still* pass!

I looked into it a bit and IMHO the problem is because of
RedeliveryErrorHandler.isDone() [3] which somehow has the effect of:

	 - x - = +     <==     minus multiplied with minus == plus

That's if answer value assigned through:

boolean answer = isCancelledOrInterrupted(exchange);

Is *already* true we should return !answer because as the method name says
we ask for if isDone(). I changed the logic of that method on my workspace
to something making better sense to me and the result was an endless
retrying of routing the failed inflight exchange again and again.

In all cases I assume we've got an issue here, What do you think?



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

View raw message