You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Rahotman P <ra...@gmail.com> on 2019/01/21 07:28:30 UTC

Query on unit test

Hi,

While starting a unit test for a route, its looking for static method of a
bean, but there is no static method available. But at run time, its working
fine with non-static method. Can you provide me some solution, on this kind
of behaviour.

-- 
Regards
Rahotman
9487939018

Re: Query on unit test

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

So your bean for testing vs production is different?

You can use advice with in your unit test to replace the node in the
route that calls the bean, where you can do something else.

On Mon, Jan 21, 2019 at 10:42 AM Rahotman P <ra...@gmail.com> wrote:
>
> Hi,
>
> While starting a unit test for a route, its looking for static method of a
> bean, but there is no static method available. But at run time, its working
> fine with non-static method. Can you provide me some solution, on this kind
> of behaviour.
>
> --
> Regards
> Rahotman
> 9487939018



-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2