Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Buckminster » How to let Buckminster determine additional bundles?
How to let Buckminster determine additional bundles? [message #1062326] Fri, 07 June 2013 08:37 Go to next message
Axel Guckelsberger is currently offline Axel GuckelsbergerFriend
Messages: 354
Registered: July 2009
Senior Member
Hi all,

I am currently overhauling my continuous integration builds to have separate
jobs for different components. Each component job should gather some
metrics, run a test suite and build and publish a feature p2 repository.
This p2 repository should then be used by subsequent jobs.

The component which should be processed first is the EMF-based meta model.
The job for this pulls the corresponding git repository. After that the
following bundles are in the (Jenkins) workspace:

org....metamodel (EMF model plug-in)
org....metamodel.edit (EMF edit plug-in)
org....metamodel.tests (tests plug-in)
org....metamodel.build (build/releng feature, includes component feature)
org....metamodel.feature (component feature)

The idea is to build the build feature so that the resulting P2 repository
contains the actual component feature.
Important: the component feature includes only the metamodel and
metamodel.edit bundles - not the tests plug-in!

The first action the job performs is resolving a cquery like this:
<cq:componentQuery xmlns:cq="http://www.eclipse.org/buckminster/CQuery-1.0" resourceMap="my.rmap">
    <cq:rootRequest name="org....metamodel.build" componentType="eclipse.feature"/>
    <cq:advisorNode namePattern="^org\....\.metamodel.*\.source$" skipComponent="true"/>
</cq:componentQuery>

After that it calls the EMF ant plugin to generate EMF classes from the
model (for the model and edit plug-ins). Then some metrics are collected
using common inspection tools, like Checkstyle. Works all fine.

My problem occurs when it comes to running a test suite. I placed some
example tests inside the tests bundle using Jnario. This tests bundle
contains a file named AllTests.launch which refers to the test suite which
has been specified and generated by Jnario.

Jenkins console shows this error message:

Cannot open launch config from org....metamodel.tests/AllTests.launch

I found a forum post about this problem at
http://www.eclipse.org/forums/index.php/mv/msg/207829/780302/#msg_780302

Having read this, I guess that while the tests plug-in is part of the
Jenkins workspace, this doesn't necessarily mean that it is also recognised
by Buckminster. However, shouldn't the cquery shown above include this plug-
in, too?

I tried to add the tests plug-in as dependency to the buckminster.cspex file
of the build feature, but this did not change anything.

Do you have an idea what I need to do in order to let Buckminster detect it
properly?

Thanks in advance!

Axel

[Updated on: Fri, 07 June 2013 08:42]

Report message to a moderator

Re: How to let Buckminster determine additional bundles? [message #1062540 is a reply to message #1062326] Sat, 08 June 2013 14:09 Go to previous messageGo to next message
Lorenzo Bettini is currently offline Lorenzo BettiniFriend
Messages: 1815
Registered: July 2009
Location: Firenze, Italy
Senior Member
Hi Alex

see comments below

On 06/07/2013 10:37 AM, Axel Guckelsberger wrote:
> The component which should be processed first is the EMF-based meta model.
> The corresponding job pulls the corresponding git repository. After that the
> following bundles are in the (Jenkins) workspace:
>
> org....metamodel (EMF model plug-in)
> org....metamodel.edit (EMF edit plug-in)
> org....metamodel.tests (tests plug-in)
> org....metamodel.build (build/releng feature)
> org....metamodel.feature (component feature)
>
> The idea is to build the build feature so that the resulting P2 repository
> contains the actual component feature.
> Important: the component feature includes only the metamodel and
> metamodel.edit bundles - not the tests plug-in!
>
> The first action the job performs is resolving a cquery like this:
>
> <cq:componentQuery xmlns:cq="http://www.eclipse.org/buckminster/CQuery-1.0"
> resourceMap="my.rmap">
> <cq:rootRequest name="org....metamodel.build"
> componentType="eclipse.feature"/>
> <cq:advisorNode namePattern="^org\....\.metamodel.*\.source$"
> skipComponent="true"/>
> </cq:componentQuery>
>
> After that it calls the EMF ant plugin to generate EMF classes from the
> model (for the model and edit plug-ins). Then some metrics are collected
> using common inspection tools, like Checkstyle. Works all fine.
>
> My problem occurs when it comes to running a test suite. I placed some
> example tests inside the tests bundle using Jnario. This tests bundle
> contains a file named AllTests.launch which refers to the test suite which
> has been specified and generated by Jnario.
>
> Jenkins console shows this error message:
>
> Cannot open launch config from org....metamodel.tests/AllTests.launch
>
> I found a forum post about this problem at
> http://www.eclipse.org/forums/index.php/mv/msg/207829/780302/#msg_780302
>
> Having read this, I guess that while the tests plug-in is part of the
> Jenkins workspace, this doesn't necessarily mean that it is also recognised
> by Buckminster. However, shouldn't the cquery shown above include this plug-
> in, too?

exactly: "part of Jenkins workspace" does not imply "part of Buckminster
workspace" (i.e., an Eclipse workspace).

The cquery will import the tests plugin in the workspace only if there's
some components which depends on it...

>
> I tried to add the tests plug-in as dependency to the buckminster.cspex file
> of the build feature, but this did not change anything.
>

This at least will make buckminster import the test plugin project in
the workspace... you should see a message about that...

> Do you have an idea what I need to do in order to let Buckminster detect it
> properly?

the problem might be in the command that you use to run the Junit tests
with buckminster... when you run

junit -l <name>/<launch configuration>

<name> is NOT a filesystem path: it is the name of the component (i.e.,
project) which must be imported in the workspace. Note that the name of
the project (bundle) might differ from its actual directory name...

hope this helps
Lorenzo


--
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
HOME: http://www.lorenzobettini.it


Re: How to let Buckminster determine additional bundles? [message #1062574 is a reply to message #1062540] Sun, 09 June 2013 09:23 Go to previous message
Axel Guckelsberger is currently offline Axel GuckelsbergerFriend
Messages: 354
Registered: July 2009
Senior Member
Hi Lorenzo,

thanks for your answer.

The actual problem was that the ant task for genering the EMF bundles did also create another tests bundle which did not contain the launch file of course.
Previous Topic:Buckminster Headless with JavaCC
Next Topic:P2 provider using different repositories
Goto Forum:
  


Current Time: Fri Dec 13 16:35:38 GMT 2024

Powered by FUDForum. Page generated in 0.03359 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top