Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Headless building and testing - need advice for better organization
Headless building and testing - need advice for better organization [message #645121] Wed, 15 December 2010 16:07 Go to next message
Mike Gering is currently offline Mike GeringFriend
Messages: 41
Registered: July 2009
Member
I have a working headless build and junit test setup, but I'm not happy
with how I've structured it. I'm doing a feature build. I have the base
code structured in one feature (F) and unit test code structured in a
separate feature (T). The plugins in T naturally depend on those in F.
The build output is a p2 repository with just F (not to include T). My
build process is two steps: 1) build F and its repo, 2) build T and run
the tests. Currently, I have to define T such that it *includes* F so
that its dependencies on F are resolved, essentially building F twice.
Is there a better way to build F, T, and the repository?

To run the unit tests, my script copies all the plugins for T and F into
a test platform/dropins directory. Is there a better way to setup a test
platform?

I've searched the wikis, this forum, and some eclipse dev projects, but
haven't found an answer to these questions.

Thanks,
Mike Gering
Re: Headless building and testing - need advice for better organization [message #645137 is a reply to message #645121] Wed, 15 December 2010 16:43 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

Hi,

You should try the following workflow:
1. build F and its repo.
2. Get a copy of Eclipse, and install F from repo into it.
3. build T (use the pluginPath property at build-time to point on the plugins/ folder containing Eclipse and your plugins).
4. Install T in your Eclipse (copy plugins/ or use p2)
5. Run tests.

HTH,
--
Mickael Istria -- BonitaSoft S.A.
http://www.bonitasoft.com/products/BPM_download.php
Re: Headless building and testing - need advice for better organization [message #645147 is a reply to message #645137] Wed, 15 December 2010 17:06 Go to previous messageGo to next message
Mike Gering is currently offline Mike GeringFriend
Messages: 41
Registered: July 2009
Member
Thanks! I'll try that. But if you could elaborate a little on your point
(2), that would help. Is there an ant task for installing from a repo
into a target platform? One additional problem with my current workflow
where I copy the plugins into dropins/ is that I think it will break in
the future if a plugin should require unpacking for installation.

Mike
On 12/15/2010 11:43 AM, Mickael Istria wrote:
> Hi,
>
> You should try the following workflow:
> 1. build F and its repo.
> 2. Get a copy of Eclipse, and install F from repo into it.
> 3. build T (use the pluginPath property at build-time to point on the
> plugins/ folder containing Eclipse and your plugins).
> 4. Install T in your Eclipse (copy plugins/ or use p2)
> 5. Run tests.
>
> HTH,
Re: Headless building and testing - need advice for better organization [message #645257 is a reply to message #645147] Thu, 16 December 2010 09:46 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

Le 15/12/2010 18:06, Mike Gering a écrit :
> Thanks! I'll try that. But if you could elaborate a little on your point (2), that would help. Is there an ant task for installing from a repo into a target platform? One additional problem with my current workflow where I copy the plugins into dropins/ is that I think it will break in the future if a plugin should require unpacking for installation.

I personnally don't use an ant task, but p2 director to install features in scripts. See
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse. platform.doc.isv/guide/p2_director.html
It will take care of dependency management, unpacking and everything necessary to get it working easily.

--
Mickael Istria -- BonitaSoft S.A.
http://www.bonitasoft.com/products/BPM_download.php
Re: Headless building and testing - need advice for better organization [message #645285 is a reply to message #645121] Thu, 16 December 2010 12:57 Go to previous message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

As Mickael mentioned, you can break your build up into to separate
builds. If F is outputing a p2 repo, when you go to build T you cat
simply include F's p2 repo in the repo2runnable task (transformedRepo
and such).

The other option is to build everything at once. When it's time to
test, install F and T and run your tests. The current automated tests
that the Eclipse SDK uses in 3.7 have been switched to p2/install
instead of unzipping.

Then create a new p2 repo as the output of the build, and use p2.mirror
to mirror the F features and ignore the T ones.

PW

--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm


Previous Topic:Contribute/extend manifest editor functionality?
Next Topic:root files mechanism does not copy empty directories
Goto Forum:
  


Current Time: Thu Apr 18 08:38:18 GMT 2024

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

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

Back to the top