You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by be...@apache.org on 2011/10/09 21:19:38 UTC
svn commit: r1180695 - in
/maven/core-integration-testing/trunk/core-it-suite/src/test:
java/org/apache/maven/it/ resources/mng-5135/ resources/mng-5135/module/
resources/mng-5135/repo/ resources/mng-5135/repo/org/
resources/mng-5135/repo/org/apache/ r...
Author: bentmann
Date: Sun Oct 9 19:19:38 2011
New Revision: 1180695
URL: http://svn.apache.org/viewvc?rev=1180695&view=rev
Log:
[MNG-5135] Regression: in some cases aggregator mojo is unable to resolve dependencies with custom packaging
o Added IT
Added:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/ (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1-it.jar (with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1.pom
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml (with props)
Modified:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
Modified: maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java?rev=1180695&r1=1180694&r2=1180695&view=diff
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java (original)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java Sun Oct 9 19:19:38 2011
@@ -83,6 +83,7 @@ public class IntegrationTestSuite
// -------------------------------------------------------------------------------------------------------------
// suite.addTestSuite( MavenIT0108SnapshotUpdateTest.class ); -- MNG-3137
+ suite.addTestSuite( MavenITmng5135AggregatorDepResolutionModuleExtensionTest.class );
suite.addTestSuite( MavenITmng5096ExclusionAtDependencyWithImpliedClassifierTest.class );
suite.addTestSuite( MavenITmng5064SuppressSnapshotUpdatesTest.class );
suite.addTestSuite( MavenITmng5019StringBasedCompLookupFromChildPluginRealmTest.class );
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java?rev=1180695&view=auto
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java (added)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java Sun Oct 9 19:19:38 2011
@@ -0,0 +1,66 @@
+package org.apache.maven.it;
+
+/*
+ * 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.
+ */
+
+import org.apache.maven.it.Verifier;
+import org.apache.maven.it.util.ResourceExtractor;
+
+import java.io.File;
+import java.util.List;
+
+/**
+ * This is a test set for <a href="http://jira.codehaus.org/browse/MNG-5135">MNG-5135</a>.
+ *
+ * @author Benjamin Bentmann
+ */
+public class MavenITmng5135AggregatorDepResolutionModuleExtensionTest
+ extends AbstractMavenIntegrationTestCase
+{
+
+ public MavenITmng5135AggregatorDepResolutionModuleExtensionTest()
+ {
+ super( "[2.0.9,3.0-alpha-1),[3.0.4,)" );
+ }
+
+ /**
+ * Verify that dependency resolution for aggregator mojos considers the extensions that apply to a given module.
+ */
+ public void testit()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5135" );
+
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.setAutoclean( false );
+ verifier.deleteDirectory( "target" );
+ verifier.deleteArtifacts( "org.apache.maven.its.mng5135" );
+ verifier.getCliOptions().add( "-s" );
+ verifier.getCliOptions().add( "settings.xml" );
+ verifier.filterFile( "settings-template.xml", "settings.xml", "UTF-8", verifier.newDefaultFilterProperties() );
+ verifier.executeGoal( "org.apache.maven.its.plugins:maven-it-plugin-dependency-resolution:aggregate-test" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+
+ List compile = verifier.loadLines( "target/module.txt", "UTF-8" );
+
+ assertTrue( compile.toString(), compile.contains( "dep-0.1-it.jar" ) );
+ }
+
+}
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5135AggregatorDepResolutionModuleExtensionTest.java
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/
------------------------------------------------------------------------------
bugtraq:number = true
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml?rev=1180695&view=auto
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml (added)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml Sun Oct 9 19:19:38 2011
@@ -0,0 +1,55 @@
+<?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>
+ <modelVersion>4.0.0</modelVersion>
+
+ <groupId>org.apache.maven.its.mng5135</groupId>
+ <artifactId>module</artifactId>
+ <version>0.1</version>
+ <packaging>jar</packaging>
+
+ <name>Maven Integration Test :: MNG-5135 :: Module</name>
+ <description>
+ Verify that dependency resolution for aggregator mojos considers the extensions that apply to a given module.
+ </description>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.maven.its.mng5135</groupId>
+ <artifactId>dep</artifactId>
+ <version>0.1</version>
+ <type>it-artifact</type>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <!-- aggregators running from the top-level POM better respect this extension and its artifact handler when resolving the above dependency -->
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>maven-it-plugin-packaging</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ <extensions>true</extensions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/module/pom.xml
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml?rev=1180695&view=auto
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml (added)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml Sun Oct 9 19:19:38 2011
@@ -0,0 +1,56 @@
+<?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>
+ <modelVersion>4.0.0</modelVersion>
+
+ <groupId>org.apache.maven.its.mng5135</groupId>
+ <artifactId>test</artifactId>
+ <version>0.1</version>
+ <packaging>pom</packaging>
+
+ <name>Maven Integration Test :: MNG-5135</name>
+ <description>
+ Verify that dependency resolution for aggregator mojos considers the extensions that apply to a given module.
+ </description>
+
+ <modules>
+ <module>module</module>
+ </modules>
+
+ <build>
+ <!--
+ NOTE: Unlike the sub module, this POM does not have any extensions, in particular, this project does not know about
+ the artifact handler for "it-artifact" used in the sub module.
+ -->
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>maven-it-plugin-dependency-resolution</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ <configuration>
+ <testClassPath>target/@artifactId@.txt</testClassPath>
+ <significantPathLevels>1</significantPathLevels>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/pom.xml
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/
------------------------------------------------------------------------------
bugtraq:number = true
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1-it.jar
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1-it.jar?rev=1180695&view=auto
==============================================================================
Binary file - no diff available.
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1-it.jar
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1.pom
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1.pom?rev=1180695&view=auto
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1.pom (added)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/repo/org/apache/maven/its/mng5135/dep/0.1/dep-0.1.pom Sun Oct 9 19:19:38 2011
@@ -0,0 +1,36 @@
+<?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>
+ <modelVersion>4.0.0</modelVersion>
+
+ <groupId>org.apache.maven.its.mng5135</groupId>
+ <artifactId>dep</artifactId>
+ <version>0.1</version>
+ <packaging>jar</packaging>
+
+ <distributionManagement>
+ <repository>
+ <id>maven-core-it</id>
+ <url>file:///${basedir}/repo</url>
+ </repository>
+ </distributionManagement>
+</project>
Added: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml
URL: http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml?rev=1180695&view=auto
==============================================================================
--- maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml (added)
+++ maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml Sun Oct 9 19:19:38 2011
@@ -0,0 +1,43 @@
+<?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.
+-->
+
+<settings>
+ <profiles>
+ <profile>
+ <id>maven-core-it-repo</id>
+ <repositories>
+ <repository>
+ <id>maven-core-it</id>
+ <url>@baseurl@/repo</url>
+ <releases>
+ <checksumPolicy>ignore</checksumPolicy>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ </snapshots>
+ </repository>
+ </repositories>
+ </profile>
+ </profiles>
+ <activeProfiles>
+ <activeProfile>maven-core-it-repo</activeProfile>
+ </activeProfiles>
+</settings>
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-5135/settings-template.xml
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision