o adding per goal/mojo configuration

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@163183 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jason van Zyl 2004-10-03 19:28:25 +00:00
parent 6ec6f3d88b
commit 5bfcebab21
2 changed files with 23 additions and 0 deletions

View File

@ -28,6 +28,7 @@ import org.apache.maven.model.Resource;
import org.apache.maven.model.Site;
import org.apache.maven.model.UnitTest;
import org.apache.maven.model.Plugin;
import org.apache.maven.model.Goal;
import org.apache.maven.project.MavenProject;
import org.apache.maven.MavenTestCase;
@ -77,6 +78,20 @@ public class CanonicalProjectBuilderTest
assertEquals( "Continuum", properties.getProperty( "plexusApplicationName" ) );
// ----------------------------------------------------------------------
// Goal specific configuration
// ----------------------------------------------------------------------
List goals = plugin.getGoals();
Goal g0 = (Goal) goals.get( 0 );
assertEquals( "plexus:runtime", g0.getId() );
Properties goalProperties = g0.getConfiguration();
assertEquals( "ContinuumPro", goalProperties.getProperty( "plexusApplicationName" ) );
// Plugin1 [antlr]
}
}

View File

@ -15,6 +15,14 @@
<plexusConfigurationPropertiesFile>src/conf/plexus.properties</plexusConfigurationPropertiesFile>
<plexusApplicationName>Continuum</plexusApplicationName>
</configuration>
<goals>
<goal>
<id>plexus:runtime</id>
<configuration>
<plexusApplicationName>ContinuumPro</plexusApplicationName>
</configuration>
</goal>
</goals>
</plugin>
</plugins>
</project>