Author: bentmann
Date: Sun Oct 9 17:40:30 2011
New Revision: 1180662
URL: http://svn.apache.org/viewvc?rev=1180662&view=rev
Log:
[MNG-4963] [regression] Parent POM not downloaded when settings define global
mirror and one snapshot repo but no other release repository
o Added IT
Added:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/
(with props)
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/parent-0.1.pom
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/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=1180662&r1=1180661&r2=1180662&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 17:40:30 2011
@@ -93,6 +93,7 @@ public class IntegrationTestSuite
suite.addTestSuite(
MavenITmng4975ProfileInjectedPluginExecutionOrderTest.class );
suite.addTestSuite(
MavenITmng4973ExtensionVisibleToPluginInReactorTest.class );
suite.addTestSuite( MavenITmng4966AbnormalUrlPreservationTest.class );
+ suite.addTestSuite( MavenITmng4963ParentResolutionFromMirrorTest.class
);
suite.addTestSuite( MavenITmng4960MakeLikeReactorResumeTest.class );
suite.addTestSuite(
MavenITmng4955LocalVsRemoteSnapshotResolutionTest.class );
suite.addTestSuite( MavenITmng4952MetadataReleaseInfoUpdateTest.class
);
@@ -268,7 +269,7 @@ public class IntegrationTestSuite
suite.addTestSuite( MavenITmng4196ExclusionOnPluginDepTest.class );
suite.addTestSuite( MavenITmng4193UniqueRepoIdTest.class );
suite.addTestSuite( MavenITmng4190MirrorRepoMergingTest.class );
- suite.addTestSuite( MavenITmng4189UniqueVersionSnapshotTest.class );
+ suite.addTestSuite( MavenITmng4189UniqueVersionSnapshotTest.class );
suite.addTestSuite( MavenITmng4180PerDependencyExclusionsTest.class );
suite.addTestSuite( MavenITmng4172EmptyDependencySetTest.class );
suite.addTestSuite( MavenITmng4166HideCoreCommonsCliTest.class );
@@ -404,7 +405,7 @@ public class IntegrationTestSuite
suite.addTestSuite( MavenITmng3535SelfReferentialPropertiesTest.class
);
suite.addTestSuite( MavenITmng3530DynamicPOMInterpolationTest.class );
suite.addTestSuite( MavenITmng3529QuotedCliArgTest.class );
- suite.addTestSuite(
MavenITmng3506ArtifactHandlersFromPluginsTest.class);
+ suite.addTestSuite(
MavenITmng3506ArtifactHandlersFromPluginsTest.class );
suite.addTestSuite( MavenITmng3503Xpp3ShadingTest.class );
suite.addTestSuite( MavenITmng3498ForkToOtherMojoTest.class );
suite.addTestSuite( MavenITmng3485OverrideWagonExtensionTest.class );
Added:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
URL:
http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java?rev=1180662&view=auto
==============================================================================
---
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
(added)
+++
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
Sun Oct 9 17:40:30 2011
@@ -0,0 +1,63 @@
+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;
+
+/**
+ * This is a test set for <a
href="http://jira.codehaus.org/browse/MNG-4963">MNG-4963</a>.
+ *
+ * @author Benjamin Bentmann
+ */
+public class MavenITmng4963ParentResolutionFromMirrorTest
+ extends AbstractMavenIntegrationTestCase
+{
+
+ public MavenITmng4963ParentResolutionFromMirrorTest()
+ {
+ super( "[2.0.5,3.0-alpha-1),[3.0.3,)" );
+ }
+
+ /**
+ * Verify that a released parent POM can be resolved when the settings
define only a snapshot repository
+ * which is subject to mirroring. Technically, this means to properly
aggregate the built-in central repo
+ * definition with the declared snapshot repo when both are mirrored.
+ */
+ public void testit()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(),
"/mng-4963" );
+
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.setAutoclean( false );
+ verifier.deleteDirectory( "target" );
+ verifier.deleteArtifacts( "org.apache.maven.its.mng4963" );
+ verifier.getCliOptions().add( "-s" );
+ verifier.getCliOptions().add( "settings.xml" );
+ verifier.filterFile( "settings-template.xml", "settings.xml", "UTF-8",
verifier.newDefaultFilterProperties() );
+ verifier.executeGoal( "validate" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+ }
+
+}
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4963ParentResolutionFromMirrorTest.java
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/
------------------------------------------------------------------------------
bugtraq:number = true
Added:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
URL:
http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml?rev=1180662&view=auto
==============================================================================
---
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
(added)
+++
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
Sun Oct 9 17:40:30 2011
@@ -0,0 +1,41 @@
+<?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>
+
+ <parent>
+ <groupId>org.apache.maven.its.mng4963</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.1</version>
+ </parent>
+
+ <groupId>org.apache.maven.its.mng4963</groupId>
+ <artifactId>test</artifactId>
+ <packaging>jar</packaging>
+
+ <name>Maven Integration Test :: MNG-4963</name>
+ <description>
+ Verify that a released parent POM can be resolved when the settings define
only a snapshot repository
+ which is subject to mirroring. Technically, this means to properly
aggregate the built-in central repo
+ definition with the declared snapshot repo when both are mirrored.
+ </description>
+</project>
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/pom.xml
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/
------------------------------------------------------------------------------
bugtraq:number = true
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/
------------------------------------------------------------------------------
bugtraq:number = true
Added:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/parent-0.1.pom
URL:
http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/parent-0.1.pom?rev=1180662&view=auto
==============================================================================
---
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/parent-0.1.pom
(added)
+++
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/repo/org/apache/maven/its/mng4963/parent/0.1/parent-0.1.pom
Sun Oct 9 17:40:30 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.mng4963</groupId>
+ <artifactId>parent</artifactId>
+ <version>0.1</version>
+ <packaging>pom</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-4963/settings-template.xml
URL:
http://svn.apache.org/viewvc/maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/settings-template.xml?rev=1180662&view=auto
==============================================================================
---
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/settings-template.xml
(added)
+++
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/settings-template.xml
Sun Oct 9 17:40:30 2011
@@ -0,0 +1,53 @@
+<?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>
+ <mirrors>
+ <mirror>
+ <id>maven-core-it-mirror</id>
+ <url>@baseurl@/repo</url>
+ <mirrorOf>*</mirrorOf>
+ </mirror>
+ </mirrors>
+ <profiles>
+ <profile>
+ <!--
+ NOTE: It's essential to not define a repo with releases=true here, this
is also why the it-defaults are overridden.
+ -->
+ <id>it-defaults</id>
+ <repositories>
+ <repository>
+ <id>maven-core-it</id>
+ <url>@baseurl@/repo</url>
+ <releases>
+ <enabled>false</enabled>
+ </releases>
+ <snapshots>
+ <checksumPolicy>ignore</checksumPolicy>
+ </snapshots>
+ </repository>
+ </repositories>
+ </profile>
+ </profiles>
+ <activeProfiles>
+ <activeProfile>it-defaults</activeProfile>
+ </activeProfiles>
+</settings>
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/settings-template.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
maven/core-integration-testing/trunk/core-it-suite/src/test/resources/mng-4963/settings-template.xml
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision