I recently got invited by Gilles J. Iachelini to join a beer bash in Bern, Switzerland on the 15th April.

It's arranged by the Swiss East Eclipse user group so if you are around and interested in Eclipse and JBoss Tools come and say Hi.

Giles invite reminded me of a few other things I wanted to spread the word about...

Eclipse Plugin Code Coverage

I met Gilles while I were at EclipseCon and he were doing an EclEmma tutorial together with Marc R. Hoffman.

EclEmma is really nice Eclipse plugin that makes it ultrasimple to run a normal Java project and get code coverage information via Emma.

But since I mostly develop plugins these days I were more interested in using it with Eclipse which is a pain with any other code coverage tools I have tried.

Luckily Marc showed me a very simple trick to get Emma to do code coverage for any Eclipse plugin.

You basically just add their special EclEmma plugin next to the org.eclipse.osgi plugin and then run Eclipse with

-Dosgi.framework.extensions=com.mountainminds.eclemma.osgihook
This allows Emma to be used to enhance any classes loaded by Eclipse runtime and here by be able to generate a code coverage html report and Emma session file when Eclipse exit.

The HTML report can be directly viewed in a browser but will not include classes that were not loaded, but if you load the Emma session file with EclEmma you can get those statistics too.

?BROKEN LINK?

Extremely simple and straightforward.

I hope Marc will integrate this soon into EclEmma so it becomes even easier to run.

You can read the details about this trick on EclEmma website

Useful sourceprovider lookup

Another useful plugin comes from our own Rob Stryker which the other day got annoyed when he were debugging four different versions of Eclipse and WTP combinations.

He were being fed up with having to constantly setup the matching plugins and source in the debugger. All the current source-lookup options assumes you point to unpacked sources or single archives. That just does not cut it when it comes to Eclipse which consists of multiple src.zip files spread across multiple directories.

Hence Rob created a sourceprovider that can be added to any Debug launch and then tell it about the root directory of an Eclipse installation and it recursively scans for src.zip files and adds it as a place where Eclipse will look for sources.

A great time saver, also for non-eclipse projects that has many src.zip files.

The org.jboss.tools.labs.pde.sourceprovider is available in source form from JBoss Tools svn


Back to top