You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Muhammad Ichsan <ic...@gmail.com> on 2010/07/09 13:49:43 UTC

Testing using Pax Exam

How to test my Camel application using Pax Exam? I need to test across
bundles which requires Active MQ ("uri=activemq:blahblah") using OSGi.
I tried to load the activemq-broker feature but failed. It needs
/etc/active-broker.xml configuration. I don't know where to put the
file and how.

Sorry if you think this is OOT. Would you please suggest me where to
ask this question.

Thanks

-- 
~The best men are men who benefit to others
http://michsan.web.id 一緒に勉強しましょう!

Yang berkualitas memang beda rasanya!
http://rizqi-cookies.com

Re: Testing using Pax Exam

Posted by Charles Moulliard <cm...@gmail.com>.
The installation of the file 'activemq-broker.xml' is a little bit different
from the other as we use a protocol created specifically for Fuse ESB -->
uri:spring

During the installation process the karaf spring deployer pick up the file
'activemq-broker.xml', create a jar containing it in the directory
META-INF/spring/activemq-broker.xml and generates the MANIFEST.mf who will
contain the info required by OSGI framework but also by Spring.

There is no command to deploy it through pax-exam except if you get the
bundle generated and installed in the data/cache directory and copy it
somewhere in your maven repo. In this case, you can deploy it using pax-exam

Kind regards,

Charles Moulliard

Senior Enterprise Architect (J2EE, .NET, SOA)
Apache Camel - ServiceMix Committer
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Blog : http://cmoulliard.blogspot.com |  Twitter :
http://twitter.com/cmoulliard
Linkedin : http://www.linkedin.com/in/charlesmoulliard | Skype: cmoulliard


On Fri, Jul 16, 2010 at 3:10 PM, Muhammad Ichsan <ic...@gmail.com> wrote:

> On Wed, Jul 14, 2010 at 8:41 PM, Willem.Jiang <wi...@gmail.com>
> wrote:
> >
> > Maybe you can consider to put the activemq-broker file into your unit
> test
> > test resource directory.
>
> No, it's not working. It still complains about missing
> [spring:file:etc/activemq-broker.xml]. If you want to see how I
> produce this error, you can see here:
> http://fusesource.com/forums/thread.jspa?messageID=7200&#7200
>
> Thanks
>
> --
> ~The best men are men who benefit to others
> http://michsan.web.id 一緒に勉強しましょう!
>
> Yang berkualitas memang beda rasanya!
> http://rizqi-cookies.com
>

Re: Testing using Pax Exam

Posted by Muhammad Ichsan <ic...@gmail.com>.
On Wed, Jul 14, 2010 at 8:41 PM, Willem.Jiang <wi...@gmail.com> wrote:
>
> Maybe you can consider to put the activemq-broker file into your unit test
> test resource directory.

No, it's not working. It still complains about missing
[spring:file:etc/activemq-broker.xml]. If you want to see how I
produce this error, you can see here:
http://fusesource.com/forums/thread.jspa?messageID=7200&#7200

Thanks

-- 
~The best men are men who benefit to others
http://michsan.web.id 一緒に勉強しましょう!

Yang berkualitas memang beda rasanya!
http://rizqi-cookies.com

Re: Testing using Pax Exam

Posted by "Willem.Jiang" <wi...@gmail.com>.
Maybe you can consider to put the activemq-broker file into your unit test
test resource directory.
Pax Exam should have no trouble to load the file from the test resource
directory.

Willem
----------------------------------
Apache Camel, Apache CXF committer
Open SOA http://www.fusesource.com
Blog http://willemjiang.blogspot.com
Tiwtter http://twitter.com/willemjiang 
-- 
View this message in context: http://camel.465427.n5.nabble.com/Testing-using-Pax-Exam-tp1045472p1092821.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Testing using Pax Exam

Posted by Muhammad Ichsan <ic...@gmail.com>.
On Fri, Jul 9, 2010 at 7:48 PM, Willem Jiang <wi...@gmail.com> wrote:
> Hi,
>
> Can you try to put the file into the WorkingDirectory of your Pax Exam?
> You can set this option from the static "configure" method.

I did set working directory as
http://fusesource.com/docs/esb/4.2/deploy_osgi/BestPractices-PaxExam.html
told me so.

workingDirectory("target/paxrunner/features/")

I copied the etc/activemq-broker.xml so that I can see
"target/paxrunner/features/etc/activemq-broker.xml"

This is not working. I still get an error stating that
"spring:file:etc/activemq-broker.xml" is not found


-- 
~The best men are men who benefit to others
http://michsan.web.id 一緒に勉強しましょう!

Yang berkualitas memang beda rasanya!
http://rizqi-cookies.com

Re: Testing using Pax Exam

Posted by Willem Jiang <wi...@gmail.com>.
Hi,

Can you try to put the file into the WorkingDirectory of your Pax Exam?
You can set this option from the static "configure" method.

Willem
----------------------------------
Apache Camel, Apache CXF committer
Open SOA http://www.fusesource.com
Blog http://willemjiang.blogspot.com
Tiwtter http://twitter.com/willemjiang

Muhammad Ichsan wrote:
> How to test my Camel application using Pax Exam? I need to test across
> bundles which requires Active MQ ("uri=activemq:blahblah") using OSGi.
> I tried to load the activemq-broker feature but failed. It needs
> /etc/active-broker.xml configuration. I don't know where to put the
> file and how.
> 
> Sorry if you think this is OOT. Would you please suggest me where to
> ask this question.
> 
> Thanks
>