You have to define all dependencies in the pax exam @Configuration.

The karaf test container of pax exam starts an empty karaf by default. Inside the @Configuration method you then define the bundles and features you need on top of this.

See https://ops4j1.jira.com/wiki/display/PAXEXAM3/Karaf+Container
and this for the full example:
https://github.com/ops4j/org.ops4j.pax.exam2/tree/master/samples/exam-itest-sample-karaf

For camel you have to install the camel feature repo and the camel features you use.

Christian

On 21.05.2014 15:13, ozzyoli wrote:
I'd like to test my camel routes (which have Http endpoints) which are
deployed on my custom karaf distro.

The problem with using Pax Exam is that the tests are executed as bundles
inside the container.

I'd like my test to treat karaf as a black box. Use a simple HttpClient to
make requests to Karaf and process the results.

If I run the test inside Pax Exam my tests fail because my dependencies
(e.g. Apache HttpClient) aren't found in any of the bundles deployed in
karaf.

I think i'm missing something obvious here, any help would be greatly
appreciated. Thank you

Oli






--
View this message in context: 
http://karaf.922171.n3.nabble.com/How-to-test-my-Camel-Routes-on-Karaf-using-Pax-Exam-tp4033218.html
Sent from the Karaf - User mailing list archive at Nabble.com.


--
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply via email to