Hi all.
I tried for days to get unit testing running with camel blueprint using the advice method. Sometimes it works (when doing a clean & install) and sometimes it does not (when doing an install without a clean)!
So I tried overwriting isMockEndpointsAndSkip. It turns out that this doesn't work as well. The advice is placed by BlueprintCamelContext but the detour is not honored:
[ main] ceptSendToMockEndpointStrategy INFO Adviced endpoint [direct://csvHandler] with mock endpoint [mock:direct:csvHandler] [ Blueprint Extender: 1] BlueprintCamelContext INFO Apache Camel 2.11.0 (CamelContext: blueprintContext) is starting [ Blueprint Extender: 1] BlueprintCamelContext INFO Route: poller started and consuming from: Endpoint[file://C:%5Cproject%5Cjava%5Ctest%5Cfuse-projects%5Ctutorial%5Ccsv-import-tut2%5Cimport?delay=100&doneFileName=%24%7Bfile%3Aname%7D.done&include=article%5B0-9%5D%7B14%7D.csv&initialDelay=50&move=success&moveFailed=failed] [ Blueprint Extender: 1] BlueprintCamelContext INFO Route: csv-handler started and consuming from: Endpoint[direct://csvHandler] [ Blueprint Extender: 1] BlueprintCamelContext INFO Total 2 routes, of which 2 is started. [ Blueprint Extender: 1] BlueprintCamelContext INFO Apache Camel 2.11.0 (CamelContext: blueprintContext) started in 0.019 seconds [ial%5Ccsv-import-tut2%5Cimport] poller INFO Whole file: [ial%5Ccsv-import-tut2%5Cimport] csv-handler INFO List of records: []
As you can see, the csv-handler endpoint is still invoked!
Please help!
Best regards,
Alexander.
Yeah seems there is a bug. I have logged a ticket