maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dipl.-Ing. Torsten Liermann" <l...@liermann-it.de>
Subject Help: mojo works in maven 2.x but not in maven 3.x
Date Wed, 23 Mar 2011 17:17:13 GMT
Hi,

(sorry, I can't speak english) I'm using a simple mojo that extends the classpath for unit
tests via 
the surefire plugin and his parameter additionalClasspathElement.

The mojo works with maven 2.x but not with maven 3.x In maven 3.x the sure fire plugin runs
without the addtionalClasspathElement.

Here is a code snippet of the mojo:

for (Object object : plugins) {
            if ("maven-surefire-plugin".equals(((Plugin) object).getArtifactId())) {
     Xpp3Dom config =
         (Xpp3Dom) plugin.getConfiguration();
     Xpp3Dom additionalClasspathElements = new Xpp3Dom("additionalClasspathElements");
     Xpp3Dom additionalElement = new Xpp3Dom("additionalClasspathElement");
     additionalElement.setValue("d:\\temp\\xyz.jar");
     additionalClasspathElements.addChild(additionalElement);
   
}



What is wrong?

Thanks for a hint
Torsten


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Mime
View raw message