Hi,

As Lin said, Pax Exam tests are just ordinary JUnit tests and can be
run from Eclipse w/o any additional tweaking. Unfortunately, there's
one little catch that is introduced by Pax Exam configuration used in
Aries itests projects. That is why you're observing this weird error.

These tests need to download Maven artifacts. Versions of these
artifacts are not specified inside the Pax Exam tests. It is so,
because it's cleaner to keep those versions in a single location - in
pom.xml (and not in both pom.xml and JUnit test). The issue is that
Pax Exam tests do not have access to pom.xml. That is why, during a
build of an itests project, a properties file with all details on
artifacts that are dependencies of the itests project is being
generated. This is done using ServiceMix's Mojo - depends-maven-plugin
- or a similar Mojo from OPS4J Pax (I don't remember its name). The
file is being added to target\classes\META-INF\maven\ and is named
dependencies.properties.

Conclusion: You need to run a Maven build to have this file generated.
If it's present, you'll be able to run tests from Eclipse until this
file is deleted (when running 'mvn clean' or by Eclipse itself). Oh,
one more thing - this plugin should attached to the
'generate-resources' phase of a Maven lifecycle, so it should be
enough to just run this Maven phase and then invoke tests from
Eclipse.

Thanks,
  Bartek

2010/8/18 Lin Sun <[email protected]>:
> Hi,
>
> Are you trying to run the itests from Eclipse or just the junit tests
> from Eclipse?
>
> I personally have never run the itests from Eclipse, but running junit
> tests from Eclipse should be doable.
>
> Lin
>
> On Wed, Aug 18, 2010 at 11:38 AM, Alexandros Karypidis
> <[email protected]> wrote:
>> Hi,
>>
>> I'm trying to run the integration tests from within Eclipse. I've never used
>> pax-exam before. As far as I can understand I need to configure pax-exam to
>> create an OSGi container in order to deply the test bundle. What kind of
>> launch configuration should I use in Eclispe to have the test run within an
>> Equinox instance? My workspace has all Aries modules in it, imported from an
>> "mvn eclipse:eclipse" after a successful build.
>>
>> Thanks,
>> Alexander
>>
>>
>>
>

Reply via email to