You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by jv...@apache.org on 2009/05/21 14:56:09 UTC
svn commit: r777100 - in
/maven/components/branches/MNG-2766/maven-core/src/test:
java/org/apache/maven/lifecycle/
projects/lifecycle-executor/project-with-multiple-executions/
projects/lifecycle-executor/project-with-multiple-executions/src/
projects/...
Author: jvanzyl
Date: Thu May 21 12:56:07 2009
New Revision: 777100
URL: http://svn.apache.org/viewvc?rev=777100&view=rev
Log:
o adding test with multiple executions
Added:
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml (with props)
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/remote-resources.mdo
maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/supplemental-model.mdo
Modified:
maven/components/branches/MNG-2766/maven-core/src/test/java/org/apache/maven/lifecycle/LifecycleExecutorTest.java
Modified: maven/components/branches/MNG-2766/maven-core/src/test/java/org/apache/maven/lifecycle/LifecycleExecutorTest.java
URL: http://svn.apache.org/viewvc/maven/components/branches/MNG-2766/maven-core/src/test/java/org/apache/maven/lifecycle/LifecycleExecutorTest.java?rev=777100&r1=777099&r2=777100&view=diff
==============================================================================
--- maven/components/branches/MNG-2766/maven-core/src/test/java/org/apache/maven/lifecycle/LifecycleExecutorTest.java (original)
+++ maven/components/branches/MNG-2766/maven-core/src/test/java/org/apache/maven/lifecycle/LifecycleExecutorTest.java Thu May 21 12:56:07 2009
@@ -8,6 +8,7 @@
import org.apache.maven.exception.ExceptionHandler;
import org.apache.maven.execution.MavenSession;
import org.apache.maven.model.Plugin;
+import org.apache.maven.model.PluginExecution;
import org.apache.maven.plugin.MojoExecution;
import org.apache.maven.plugin.descriptor.MojoDescriptor;
import org.codehaus.plexus.component.annotations.Requirement;
@@ -131,13 +132,24 @@
File pom = getProject( "project-with-multiple-executions" );
MavenSession session = createMavenSession( pom );
assertEquals( "project-with-multiple-executions", session.getCurrentProject().getArtifactId() );
- assertEquals( "1.0", session.getCurrentProject().getVersion() );
+ assertEquals( "1.0.1", session.getCurrentProject().getVersion() );
List<MojoExecution> lifecyclePlan = lifecycleExecutor.calculateBuildPlan( session, "clean", "install" );
+ /*
+ for ( Plugin p : session.getCurrentProject().getBuildPlugins() )
+ {
+ for ( PluginExecution pe : p.getExecutions() )
+ {
+ System.out.println( pe.getConfiguration() );
+ }
+ }
+
for ( MojoExecution me : lifecyclePlan )
{
- System.out.println( me.getExecutionId() );
+ System.out.println( me.getMojoDescriptor().getFullGoalName() );
+ //System.out.println( me.getConfiguration() ) ;
}
+ */
/*
//[01] clean:clean
Added: maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml
URL: http://svn.apache.org/viewvc/maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml?rev=777100&view=auto
==============================================================================
--- maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml (added)
+++ maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml Thu May 21 12:56:07 2009
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>project-with-multiple-executions</artifactId>
+ <version>1.0.1</version>
+ <packaging>maven-plugin</packaging>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.codehaus.plexus</groupId>
+ <artifactId>plexus-utils</artifactId>
+ <version>1.5.8</version>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.modello</groupId>
+ <artifactId>modello-maven-plugin</artifactId>
+ <version>1.0.1</version>
+ <executions>
+ <execution>
+ <id>site-docs</id>
+ <phase>pre-site</phase>
+ <goals>
+ <goal>xdoc</goal>
+ <goal>xsd</goal>
+ </goals>
+ <configuration>
+ <version>1.0.0</version>
+ <models>
+ <model>src/main/mdo/supplemental-model.mdo</model>
+ </models>
+ </configuration>
+ </execution>
+ <execution>
+ <id>site-docs-supplement</id>
+ <phase>pre-site</phase>
+ <goals>
+ <goal>xdoc</goal>
+ <goal>xsd</goal>
+ </goals>
+ <configuration>
+ <version>1.1.0</version>
+ <models>
+ <model>src/main/mdo/remote-resources.mdo</model>
+ </models>
+ </configuration>
+ </execution>
+ <execution>
+ <id>remote-resources</id>
+ <goals>
+ <goal>xpp3-writer</goal>
+ <goal>java</goal>
+ <goal>xpp3-reader</goal>
+ </goals>
+ <configuration>
+ <version>1.1.0</version>
+ <models>
+ <model>src/main/mdo/remote-resources.mdo</model>
+ </models>
+ </configuration>
+ </execution>
+ <execution>
+ <id>supplemental-models</id>
+ <goals>
+ <goal>xpp3-writer</goal>
+ <goal>java</goal>
+ <goal>xpp3-reader</goal>
+ </goals>
+ <configuration>
+ <version>1.0.0</version>
+ <models>
+ <model>src/main/mdo/supplemental-model.mdo</model>
+ </models>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/pom.xml
------------------------------------------------------------------------------
svn:keywords = "Author Date Id Revision"
Added: maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/remote-resources.mdo
URL: http://svn.apache.org/viewvc/maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/remote-resources.mdo?rev=777100&view=auto
==============================================================================
--- maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/remote-resources.mdo (added)
+++ maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/remote-resources.mdo Thu May 21 12:56:07 2009
@@ -0,0 +1,61 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<model>
+ <id>remoteResourcesBundle</id>
+ <name>RemoteResourcesBundle</name>
+ <description><![CDATA[
+ A bundle of remote resources.
+ This is the model specification for remote-resources.xml.
+ ]]></description>
+ <defaults>
+ <default>
+ <key>package</key>
+ <value>org.apache.maven.plugin.resources.remote</value>
+ </default>
+ </defaults>
+ <classes>
+ <class rootElement="true" xml.tagName="remoteResourcesBundle">
+ <name>RemoteResourcesBundle</name>
+ <version>1.1.0</version>
+ <description>Root element of the remote-resources.xml file.</description>
+ <fields>
+ <field>
+ <name>remoteResources</name>
+ <version>1.1.0</version>
+ <description><![CDATA[
+ Remote resources that are contained in a remote resources bundle.
+ ]]></description>
+ <association>
+ <type>String</type>
+ <multiplicity>*</multiplicity>
+ </association>
+ </field>
+ <field>
+ <name>sourceEncoding</name>
+ <version>1.1.0</version>
+ <description><![CDATA[
+ Source encoding of the remote resources contained in the bundle.
+ ]]></description>
+ <type>String</type>
+ </field>
+ </fields>
+ </class>
+ </classes>
+</model>
Added: maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/supplemental-model.mdo
URL: http://svn.apache.org/viewvc/maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/supplemental-model.mdo?rev=777100&view=auto
==============================================================================
--- maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/supplemental-model.mdo (added)
+++ maven/components/branches/MNG-2766/maven-core/src/test/projects/lifecycle-executor/project-with-multiple-executions/src/main/mdo/supplemental-model.mdo Thu May 21 12:56:07 2009
@@ -0,0 +1,61 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<model>
+ <id>supplementalModel</id>
+ <name>SupplementalDataModel</name>
+ <description>Provides access to supplemental POM data models.</description>
+ <defaults>
+ <default>
+ <key>package</key>
+ <value>org.apache.maven.plugin.resources.remote</value>
+ </default>
+ </defaults>
+ <classes>
+ <class rootElement="true" xml.tagName="supplementalDataModels" xsd.compositor="sequence">
+ <name>SupplementalDataModel</name>
+ <version>1.0.0</version>
+ <description>Root element of the supplemental-models.xml file.</description>
+ <fields>
+ <field xml.listStyle="flat">
+ <name>supplement</name>
+ <version>1.0.0</version>
+ <description>Snippets of POM xml files used to supplement the data model.</description>
+ <association>
+ <type>Supplement</type>
+ <multiplicity>*</multiplicity>
+ </association>
+ </field>
+ </fields>
+ </class>
+ <class>
+ <name>Supplement</name>
+ <version>1.0.0</version>
+ <description>A single supplement</description>
+ <fields>
+ <field>
+ <name>project</name>
+ <version>1.0.0</version>
+ <description>Snippets of POM xml files used to supplement the data model.</description>
+ <type>DOM</type>
+ </field>
+ </fields>
+ </class>
+ </classes>
+</model>