You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sc...@apache.org on 2017/01/16 01:37:40 UTC
[1/3] maven-integration-testing git commit: [MNG-3599] The upgrade of
Wagon to 2.10 breaks the test using older versions of wagon [Forced Update!]
Repository: maven-integration-testing
Updated Branches:
refs/heads/MNG-5958 1e4c7c36b -> 2fd74ac6d (forced update)
[MNG-3599] The upgrade of Wagon to 2.10 breaks the test using older versions of wagon
- Need to use `--legacy-local-repository` on newer maven versions
(noting workaround as MNG-6155)
Project: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/commit/ad98af7e
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/ad98af7e
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/ad98af7e
Branch: refs/heads/MNG-5958
Commit: ad98af7e77d4d392f9c3f96656959f1957923082
Parents: f31241a
Author: Stephen Connolly <st...@gmail.com>
Authored: Wed Jan 11 09:50:08 2017 +0000
Committer: Stephen Connolly <st...@gmail.com>
Committed: Wed Jan 11 20:10:26 2017 +0000
----------------------------------------------------------------------
.../apache/maven/it/IntegrationTestSuite.java | 1 +
...enITmng3599useHttpProxyForWebDAVMk2Test.java | 214 +++++++++++++++++++
...MavenITmng3599useHttpProxyForWebDAVTest.java | 4 +-
.../test/resources/bootstrap/group-7/pom.xml | 50 +++++
.../src/test/resources/bootstrap/pom.xml | 1 +
.../src/test/resources/mng-3599-mk2/pom.xml | 23 ++
.../mng-3599-mk2/settings-template.xml | 18 ++
7 files changed, 309 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java b/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
index 48051c9..5536620 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
@@ -461,6 +461,7 @@ public class IntegrationTestSuite
suite.addTestSuite( MavenITmng3607ClassLoadersUseValidUrlsTest.class );
suite.addTestSuite( MavenITmng3600DeploymentModeDefaultsTest.class );
suite.addTestSuite( MavenITmng3599useHttpProxyForWebDAVTest.class );
+ suite.addTestSuite( MavenITmng3599useHttpProxyForWebDAVMk2Test.class );
suite.addTestSuite( MavenITmng3586SystemScopePluginDependencyTest.class );
suite.addTestSuite( MavenITmng3581PluginUsesWagonDependencyTest.class );
suite.addTestSuite( MavenITmng3575HexadecimalOctalPluginParameterConfigTest.class );
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
new file mode 100644
index 0000000..0377348
--- /dev/null
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
@@ -0,0 +1,214 @@
+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 java.io.File;
+import java.io.IOException;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import org.apache.maven.it.util.ResourceExtractor;
+import org.apache.maven.shared.utils.StringUtils;
+import org.apache.maven.shared.utils.io.FileUtils;
+import org.mortbay.jetty.Handler;
+import org.mortbay.jetty.Request;
+import org.mortbay.jetty.Server;
+import org.mortbay.jetty.handler.AbstractHandler;
+
+/**
+ * This is a test set for <a href="https://issues.apache.org/jira/browse/MNG-3599">MNG-3599</a>.
+ *
+ * @author Brett Porter
+ * @author John Casey
+ * @version $Id$
+ */
+public class MavenITmng3599useHttpProxyForWebDAVMk2Test
+ extends AbstractMavenIntegrationTestCase
+{
+ private static final String LS = System.getProperty( "line.separator" );
+
+ private Server server;
+
+ private int port;
+
+ private static final String content = "<project xmlns=\"http://maven.apache.org/POM/4.0.0\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n" +
+ " xsi:schemaLocation=\"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd\">\n" +
+ " <modelVersion>4.0.0</modelVersion>\n" +
+ " <groupId>org.apache.maven.its.mng3599</groupId>\n" +
+ " <artifactId>test</artifactId>\n" +
+ " <version>1.0-SNAPSHOT</version>\n" +
+ " <name>MNG-3599</name>\n" +
+ "</project>";
+
+ public MavenITmng3599useHttpProxyForWebDAVMk2Test()
+ {
+ super( "[3.3.9,)" );
+ }
+
+ public void setUp()
+ throws Exception
+ {
+ Handler handler = new AbstractHandler()
+ {
+ public void handle( String target, HttpServletRequest request, HttpServletResponse response, int dispatch )
+ throws IOException, ServletException
+ {
+ System.out.println( "Got request for URL: '" + request.getRequestURL() + "'" );
+ System.out.flush();
+
+ response.setContentType( "text/plain" );
+
+ System.out.println( "Checking for 'Proxy-Connection' header..." );
+ if ( request.getHeader( "Proxy-Connection" ) != null )
+ {
+ response.setStatus( HttpServletResponse.SC_OK );
+ response.getWriter().println( content );
+
+ System.out.println( "Proxy-Connection found." );
+ }
+ /*
+ * 2008-09-29 Oleg: "Proxy-Connection" is not part of http spec, but an extended header, and
+ * as such cannot be expected from all the clients.
+ * Changing the code to test for more generalized case: local proxy receives a request with
+ * correct server url and resource uri
+ */
+ else if(
+ request.getRequestURI().startsWith( "/org/apache/maven/its/mng3599/test-dependency" )
+ && request.getRequestURL().toString().startsWith( "http://www.example.com" )
+ )
+ {
+ response.setStatus( HttpServletResponse.SC_OK );
+ response.getWriter().println( content );
+
+ System.out.println( "Correct proxied request 'http://www.example.com' for resource '/org/apache/maven/its/mng3599/test-dependency' found." );
+ }
+ else
+ {
+ response.setStatus( HttpServletResponse.SC_BAD_REQUEST );
+
+ System.out.println( "Proxy-Connection not found." );
+ }
+
+ ( (Request) request ).setHandled( true );
+ }
+ };
+
+ server = new Server( 0 );
+ server.setHandler( handler );
+ server.start();
+
+ port = server.getConnectors()[0].getLocalPort();
+ }
+
+ protected void tearDown()
+ throws Exception
+ {
+ super.tearDown();
+
+ if ( server != null )
+ {
+ server.stop();
+ server = null;
+ }
+ }
+
+ public void testitUseHttpProxyForHttp()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-3599-mk2" );
+
+ /*
+ * NOTE: Make sure the WebDAV extension required by the test project has been pulled down into the local
+ * repo before the actual test installs Jetty as a mirror for everything. Otherwise, we will get garbage
+ * for the JAR/POM of the extension and its dependencies when run against a vanilla repo.
+ */
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.executeGoal( "validate" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+
+ String settings = FileUtils.fileRead( new File( testDir, "settings-template.xml" ) );
+ settings = StringUtils.replace( settings, "@port@", Integer.toString( port ) );
+ String newSettings = StringUtils.replace( settings, "@protocol@", "http" );
+
+ FileUtils.fileWrite( new File( testDir, "settings.xml" ).getAbsolutePath(), newSettings );
+
+ verifier = newVerifier( testDir.getAbsolutePath() );
+
+ verifier.addCliOption( "--legacy-local-repository" ); // FIXME this is a temporary band-aid MNG-6155
+ verifier.addCliOption( "--settings" );
+ verifier.addCliOption( "settings.xml" );
+ verifier.addCliOption( "-X" );
+
+ verifier.deleteArtifacts( "org.apache.maven.its.mng3599" );
+
+ verifier.setLogFileName( "logHttp.txt" );
+ verifier.executeGoal( "compile" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+
+ verifier.assertArtifactPresent( "org.apache.maven.its.mng3599", "test-dependency", "1.0", "jar" );
+ verifier.assertArtifactContents( "org.apache.maven.its.mng3599", "test-dependency", "1.0", "jar",
+ content + LS );
+ }
+
+ /**
+ * Test that HTTP proxy is used for HTTP and for WebDAV.
+ */
+ public void testitUseHttpProxyForWebDAV()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-3599-mk2" );
+
+ /*
+ * NOTE: Make sure the WebDAV extension required by the test project has been pulled down into the local
+ * repo before the actual test installs Jetty as a mirror for everything. Otherwise, we will get garbage
+ * for the JAR/POM of the extension and its dependencies when run against a vanilla repo.
+ */
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.executeGoal( "validate" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+
+ String settings = FileUtils.fileRead( new File( testDir, "settings-template.xml" ) );
+ settings = StringUtils.replace( settings, "@port@", Integer.toString( port ) );
+ String newSettings = StringUtils.replace( settings, "@protocol@", "dav" );
+
+ FileUtils.fileWrite( new File( testDir, "settings.xml" ).getAbsolutePath(), newSettings );
+
+ verifier = newVerifier( testDir.getAbsolutePath() );
+
+ verifier.addCliOption( "--legacy-local-repository" ); // FIXME this is a temporary band-aid MNG-6155
+ verifier.addCliOption( "--settings" );
+ verifier.addCliOption( "settings.xml" );
+ verifier.addCliOption( "-X" );
+
+ verifier.deleteArtifacts( "org.apache.maven.its.mng3599" );
+
+ verifier.setLogFileName( "logDAV.txt" );
+ verifier.executeGoal( "compile" );
+ verifier.verifyErrorFreeLog();
+ verifier.resetStreams();
+
+ verifier.assertArtifactPresent( "org.apache.maven.its.mng3599", "test-dependency", "1.0", "jar" );
+ verifier.assertArtifactContents( "org.apache.maven.its.mng3599", "test-dependency", "1.0", "jar",
+ content + LS );
+ }
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVTest.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVTest.java
index a3aa6e4..4c1c114 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVTest.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVTest.java
@@ -61,7 +61,7 @@ public class MavenITmng3599useHttpProxyForWebDAVTest
public MavenITmng3599useHttpProxyForWebDAVTest()
{
- super( "(2.0.9,)" );
+ super( "(2.0.9,3.3.9)" );
}
public void setUp()
@@ -176,7 +176,7 @@ public class MavenITmng3599useHttpProxyForWebDAVTest
public void testitUseHttpProxyForWebDAV()
throws Exception
{
- requiresMavenVersion( "[2.1.0-M1,3.0-alpha-1),[3.0-beta-3,)" );
+ requiresMavenVersion( "[2.1.0-M1,3.0-alpha-1),[3.0-beta-3,3.3.9)" );
File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-3599" );
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/resources/bootstrap/group-7/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/bootstrap/group-7/pom.xml b/core-it-suite/src/test/resources/bootstrap/group-7/pom.xml
new file mode 100644
index 0000000..b7902bc
--- /dev/null
+++ b/core-it-suite/src/test/resources/bootstrap/group-7/pom.xml
@@ -0,0 +1,50 @@
+<?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.bootstrap</groupId>
+ <artifactId>maven-it-boostrap</artifactId>
+ <version>1.0</version>
+ </parent>
+
+ <groupId>org.apache.maven.its.bootstrap</groupId>
+ <artifactId>group-7</artifactId>
+ <version>1.0</version>
+ <packaging>jar</packaging>
+
+ <name>Maven Integration Test :: Boostrap :: Group-7</name>
+
+ <properties>
+ </properties>
+
+ <dependencies>
+ <!-- MNG-3599 Mk2 -->
+ <dependency>
+ <groupId>org.apache.maven.wagon</groupId>
+ <artifactId>wagon-webdav-jackrabbit</artifactId>
+ <version>2.10</version>
+ <scope>runtime</scope>
+ </dependency>
+ </dependencies>
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/resources/bootstrap/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/bootstrap/pom.xml b/core-it-suite/src/test/resources/bootstrap/pom.xml
index ed2d96e..e7aa995 100644
--- a/core-it-suite/src/test/resources/bootstrap/pom.xml
+++ b/core-it-suite/src/test/resources/bootstrap/pom.xml
@@ -43,6 +43,7 @@ under the License.
<module>group-4</module>
<module>group-5</module>
<module>group-6</module>
+ <module>group-7</module>
</modules>
<properties>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/resources/mng-3599-mk2/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-3599-mk2/pom.xml b/core-it-suite/src/test/resources/mng-3599-mk2/pom.xml
new file mode 100644
index 0000000..6937339
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-3599-mk2/pom.xml
@@ -0,0 +1,23 @@
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.maven.its.mng3599</groupId>
+ <artifactId>test</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <dependencies>
+ <dependency>
+ <groupId>${project.groupId}</groupId>
+ <artifactId>test-dependency</artifactId>
+ <version>1.0</version>
+ </dependency>
+ </dependencies>
+ <build>
+ <extensions>
+ <extension>
+ <groupId>org.apache.maven.wagon</groupId>
+ <artifactId>wagon-webdav-jackrabbit</artifactId>
+ <version>2.10</version>
+ </extension>
+ </extensions>
+ </build>
+</project>
+
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/ad98af7e/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml b/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
new file mode 100644
index 0000000..809db8f
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
@@ -0,0 +1,18 @@
+<settings>
+ <mirrors>
+ <mirror>
+ <id>test-mirror</id>
+ <url>@protocol@://www.example.com/</url>
+ <mirrorOf>*</mirrorOf>
+ </mirror>
+ </mirrors>
+ <proxies>
+ <proxy>
+ <id>http-proxy</id>
+ <protocol>http</protocol>
+ <host>127.0.0.1</host>
+ <port>@port@</port>
+ </proxy>
+ </proxies>
+</settings>
+
[3/3] maven-integration-testing git commit: [MNG-5958] restore binary
compatibility of Lifecycle.setPhases
Posted by sc...@apache.org.
[MNG-5958] restore binary compatibility of Lifecycle.setPhases
Modify tests for MNG-5805
This closes #13 #18
Project: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/commit/2fd74ac6
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/2fd74ac6
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/2fd74ac6
Branch: refs/heads/MNG-5958
Commit: 2fd74ac6d4747b11d50b78965f0d2c229fb46773
Parents: 6c86dc6
Author: Anton Tanasenko <at...@gmail.com>
Authored: Thu Jan 7 04:01:28 2016 +0200
Committer: Christian Schulte <sc...@apache.org>
Committed: Mon Jan 16 02:37:07 2017 +0100
----------------------------------------------------------------------
.../apache/maven/it/IntegrationTestSuite.java | 2 +
.../MavenITmng5805PkgTypeMojoConfiguration.java | 2 +-
...MavenITmng5805PkgTypeMojoConfiguration2.java | 30 +++++++++
...avenITmng5958LifecyclePhaseBinaryCompat.java | 45 +++++++++++++
.../test/resources/bootstrap/group-3/pom.xml | 12 ++++
.../pom.xml | 40 +++++++++++
.../mng-5958-lifecycle-phases/bad/pom.xml | 53 +++++++++++++++
.../mng-5958-lifecycle-phases/good/pom.xml | 53 +++++++++++++++
.../core-it-plugins/mng5805-extension2/pom.xml | 37 ++++++++++
.../resources/META-INF/plexus/components.xml | 71 ++++++++++++++++++++
.../core-it-plugins/mng5958-extension/pom.xml | 45 +++++++++++++
.../its/mng5958/AbstractLifecycleMapping.java | 71 ++++++++++++++++++++
.../maven/its/mng5958/BadLifecycleMapping.java | 45 +++++++++++++
.../maven/its/mng5958/GoodLifecycleMapping.java | 40 +++++++++++
.../resources/META-INF/plexus/components.xml | 62 +++++++++++++++++
core-it-support/core-it-plugins/pom.xml | 2 +
16 files changed, 609 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java b/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
index 5536620..a91eeb0 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/IntegrationTestSuite.java
@@ -106,10 +106,12 @@ public class IntegrationTestSuite
// -------------------------------------------------------------------------------------------------------------
// suite.addTestSuite( MavenIT0108SnapshotUpdateTest.class ); -- MNG-3137
+ suite.addTestSuite( MavenITmng5958LifecyclePhaseBinaryCompat.class );
suite.addTestSuite( MavenITmng5898BuildMultimoduleWithEARFailsToResolveWARTest.class );
suite.addTestSuite( MavenITmng5840ParentVersionRanges.class );
suite.addTestSuite( MavenITmng5840RelativePathReactorMatching.class );
suite.addTestSuite( MavenITmng5805PkgTypeMojoConfiguration.class );
+ suite.addTestSuite( MavenITmng5805PkgTypeMojoConfiguration2.class );
suite.addTestSuite( MavenITmng5783PluginDependencyFiltering.class );
suite.addTestSuite( MavenITmng5774ConfigurationProcessorsTest.class );
suite.addTestSuite( MavenITmng5771CoreExtensionsTest.class );
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration.java
index ada7448..5335677 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration.java
@@ -10,7 +10,7 @@ public class MavenITmng5805PkgTypeMojoConfiguration
public MavenITmng5805PkgTypeMojoConfiguration()
{
- super( "(3.3.3,)" );
+ super( "(3.3.3,3.5.0)" );
}
public void testPkgTypeMojoConfiguration()
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration2.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration2.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration2.java
new file mode 100644
index 0000000..ca1c0e3
--- /dev/null
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5805PkgTypeMojoConfiguration2.java
@@ -0,0 +1,30 @@
+package org.apache.maven.it;
+
+import java.io.File;
+
+import org.apache.maven.it.util.ResourceExtractor;
+
+public class MavenITmng5805PkgTypeMojoConfiguration2
+ extends AbstractMavenIntegrationTestCase
+{
+
+ public MavenITmng5805PkgTypeMojoConfiguration2()
+ {
+ super( "(3.3.3,)" );
+ }
+
+ public void testPkgTypeMojoConfiguration()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5805-pkg-type-mojo-configuration2" );
+
+ Verifier verifier;
+
+
+ verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.executeGoal( "validate" );
+ verifier.verifyErrorFreeLog();
+ verifier.verifyTextInLog( "CLASS_NAME=org.apache.maven.its.mng5805.TestClass1" );
+ verifier.resetStreams();
+ }
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5958LifecyclePhaseBinaryCompat.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5958LifecyclePhaseBinaryCompat.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5958LifecyclePhaseBinaryCompat.java
new file mode 100644
index 0000000..3ee3fe1
--- /dev/null
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5958LifecyclePhaseBinaryCompat.java
@@ -0,0 +1,45 @@
+package org.apache.maven.it;
+
+import java.io.File;
+
+import org.apache.maven.it.util.ResourceExtractor;
+
+public class MavenITmng5958LifecyclePhaseBinaryCompat
+ extends AbstractMavenIntegrationTestCase
+{
+
+ public MavenITmng5958LifecyclePhaseBinaryCompat()
+ {
+ super( "(3.3.9,)" );
+ }
+
+ public void testGood()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5958-lifecycle-phases/good" );
+
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ verifier.executeGoal( "validate" );
+ verifier.verifyErrorFreeLog();
+ verifier.verifyTextInLog( "CLASS_NAME=java.lang.String" );
+ verifier.resetStreams();
+ }
+
+ public void testBad()
+ throws Exception
+ {
+ File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5958-lifecycle-phases/bad" );
+
+ Verifier verifier = newVerifier( testDir.getAbsolutePath() );
+ try
+ {
+ verifier.executeGoal( "validate" );
+ }
+ catch ( VerificationException e )
+ {
+ verifier.verifyTextInLog( "[ERROR] Internal error: java.lang.ClassCastException: "
+ + "org.apache.maven.lifecycle.mapping.LifecyclePhase cannot be cast to java.lang.String -> [Help 1]" );
+ }
+ verifier.resetStreams();
+ }
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/resources/bootstrap/group-3/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/bootstrap/group-3/pom.xml b/core-it-suite/src/test/resources/bootstrap/group-3/pom.xml
index bcaaca6..9731869 100644
--- a/core-it-suite/src/test/resources/bootstrap/group-3/pom.xml
+++ b/core-it-suite/src/test/resources/bootstrap/group-3/pom.xml
@@ -136,6 +136,18 @@ under the License.
<version>${itPluginVersion}</version>
<scope>runtime</scope>
</dependency>
+ <dependency>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-extension2</artifactId>
+ <version>${itPluginVersion}</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5958-pkg-type-extension</artifactId>
+ <version>${itPluginVersion}</version>
+ <scope>runtime</scope>
+ </dependency>
<dependency>
<groupId>org.apache.maven.its.plugins</groupId>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/resources/mng-5805-pkg-type-mojo-configuration2/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5805-pkg-type-mojo-configuration2/pom.xml b/core-it-suite/src/test/resources/mng-5805-pkg-type-mojo-configuration2/pom.xml
new file mode 100644
index 0000000..b7e12f1
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5805-pkg-type-mojo-configuration2/pom.xml
@@ -0,0 +1,40 @@
+<?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>mng-5805-pkg-type-mojo-configuration</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-project2</artifactId>
+ <version>0.1</version>
+ <packaging>mng5805</packaging>
+
+ <build>
+ <extensions>
+ <extension>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-extension2</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ </extension>
+ </extensions>
+ </build>
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/bad/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/bad/pom.xml b/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/bad/pom.xml
new file mode 100644
index 0000000..d565ae0
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/bad/pom.xml
@@ -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.
+-->
+
+<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>mng-5958-lifecycle-phases</groupId>
+ <artifactId>mng-5958-lifecycle-phases-project</artifactId>
+ <version>0.1</version>
+ <packaging>mng5958-bad</packaging>
+
+ <build>
+ <extensions>
+ <extension>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5958-pkg-type-extension</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ </extension>
+ </extensions>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-plugin</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ <configuration>
+ <className>java.lang.String</className>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/good/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/good/pom.xml b/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/good/pom.xml
new file mode 100644
index 0000000..0419dcd
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5958-lifecycle-phases/good/pom.xml
@@ -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.
+-->
+
+<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>mng-5958-lifecycle-phases</groupId>
+ <artifactId>mng-5958-lifecycle-phases-project</artifactId>
+ <version>0.1</version>
+ <packaging>mng5958-good</packaging>
+
+ <build>
+ <extensions>
+ <extension>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5958-pkg-type-extension</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ </extension>
+ </extensions>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-plugin</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ <configuration>
+ <className>java.lang.String</className>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ </build>
+
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5805-extension2/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5805-extension2/pom.xml b/core-it-support/core-it-plugins/mng5805-extension2/pom.xml
new file mode 100644
index 0000000..c6a24f6
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5805-extension2/pom.xml
@@ -0,0 +1,37 @@
+<?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>
+
+ <parent>
+ <artifactId>maven-it-plugins</artifactId>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <version>2.1-SNAPSHOT</version>
+ </parent>
+
+ <artifactId>mng-5805-pkg-type-mojo-configuration-extension2</artifactId>
+ <packaging>jar</packaging>
+
+ <name>Maven IT Plugin :: mng-5805 extension mk2</name>
+
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5805-extension2/src/main/resources/META-INF/plexus/components.xml
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5805-extension2/src/main/resources/META-INF/plexus/components.xml b/core-it-support/core-it-plugins/mng5805-extension2/src/main/resources/META-INF/plexus/components.xml
new file mode 100644
index 0000000..a07744d
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5805-extension2/src/main/resources/META-INF/plexus/components.xml
@@ -0,0 +1,71 @@
+<?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.
+-->
+<component-set>
+ <components>
+
+ <component>
+ <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
+ <role-hint>mng5805</role-hint>
+ <implementation>org.apache.maven.lifecycle.mapping.DefaultLifecycleMapping</implementation>
+ <configuration>
+ <lifecycles>
+ <lifecycle>
+ <id>default</id>
+ <lifecyclePhases>
+ <validate>
+ <mojos>
+ <mojo>
+ <goal>
+ org.apache.maven.its.plugins:mng-5805-pkg-type-mojo-configuration-plugin:2.1-SNAPSHOT:test
+ </goal>
+ <configuration>
+ <className>org.apache.maven.its.mng5805.TestClass1</className>
+ </configuration>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <artifactId>mng-5805-pkg-type-mojo-configuration-plugin-dep</artifactId>
+ <version>2.1-SNAPSHOT</version>
+ </dependency>
+ </dependencies>
+ </mojo>
+ </mojos>
+ </validate>
+ </lifecyclePhases>
+ </lifecycle>
+ </lifecycles>
+ </configuration>
+ </component>
+
+ <component>
+ <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
+ <role-hint>mng5805</role-hint>
+ <implementation>
+ org.apache.maven.artifact.handler.DefaultArtifactHandler
+ </implementation>
+ <configuration>
+ <extension>zip</extension>
+ <type>mng5805</type>
+ <packaging>mng5805</packaging>
+ </configuration>
+ </component>
+
+ </components>
+</component-set>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5958-extension/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5958-extension/pom.xml b/core-it-support/core-it-plugins/mng5958-extension/pom.xml
new file mode 100644
index 0000000..5f41294
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5958-extension/pom.xml
@@ -0,0 +1,45 @@
+<?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>
+
+ <parent>
+ <artifactId>maven-it-plugins</artifactId>
+ <groupId>org.apache.maven.its.plugins</groupId>
+ <version>2.1-SNAPSHOT</version>
+ </parent>
+
+ <artifactId>mng-5958-pkg-type-extension</artifactId>
+ <packaging>jar</packaging>
+
+ <name>Maven IT Plugin :: mng-5958 extension</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.maven</groupId>
+ <artifactId>maven-core</artifactId>
+ <version>3.3.9</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+</project>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/AbstractLifecycleMapping.java
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/AbstractLifecycleMapping.java b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/AbstractLifecycleMapping.java
new file mode 100644
index 0000000..9a9db7a
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/AbstractLifecycleMapping.java
@@ -0,0 +1,71 @@
+package org.apache.maven.its.mng5958;
+
+/*
+ * 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 java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.maven.lifecycle.mapping.Lifecycle;
+import org.apache.maven.lifecycle.mapping.LifecycleMapping;
+
+/**
+ * @author Anton Tanasenko
+ */
+public abstract class AbstractLifecycleMapping implements LifecycleMapping
+{
+
+ private Map<String, Lifecycle> lifecycleMap;
+
+ public Map<String, Lifecycle> getLifecycles()
+ {
+ if ( lifecycleMap != null )
+ {
+ return lifecycleMap;
+ }
+
+ lifecycleMap = new LinkedHashMap<>();
+ Lifecycle lifecycle = new Lifecycle();
+
+ lifecycle.setId( "default" );
+ lifecycle.setPhases( initPhases() );
+
+ lifecycleMap.put( "default", lifecycle );
+ return lifecycleMap;
+ }
+
+ public Map<String, String> getPhases( String lifecycle )
+ {
+ Lifecycle lifecycleMapping = getLifecycles().get( lifecycle );
+ if ( lifecycleMapping != null )
+ {
+ return lifecycleMapping.getPhases();
+ }
+ return null;
+ }
+
+ public List<String> getOptionalMojos( String lifecycle )
+ {
+ return null;
+ }
+
+ // raw map on purpose
+ protected abstract Map initPhases();
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/BadLifecycleMapping.java
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/BadLifecycleMapping.java b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/BadLifecycleMapping.java
new file mode 100644
index 0000000..7dbf2b5
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/BadLifecycleMapping.java
@@ -0,0 +1,45 @@
+package org.apache.maven.its.mng5958;
+
+/*
+ * 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 java.util.LinkedHashMap;
+import java.util.Map;
+
+import org.apache.maven.lifecycle.mapping.LifecyclePhase;
+
+/**
+ * @author Anton Tanasenko
+ */
+public class BadLifecycleMapping extends AbstractLifecycleMapping
+{
+
+ @Override
+ protected Map<String, String> initPhases()
+ {
+ Map phases = new LinkedHashMap<>();
+
+ LifecyclePhase lp = new LifecyclePhase();
+ lp.set( "org.apache.maven.its.plugins:mng-5805-pkg-type-mojo-configuration-plugin:2.1-SNAPSHOT:test" );
+
+ phases.put( "validate", lp );
+ return phases;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/GoodLifecycleMapping.java
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/GoodLifecycleMapping.java b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/GoodLifecycleMapping.java
new file mode 100644
index 0000000..c14099d
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5958-extension/src/main/java/org/apache/maven/its/mng5958/GoodLifecycleMapping.java
@@ -0,0 +1,40 @@
+package org.apache.maven.its.mng5958;
+
+/*
+ * 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 java.util.LinkedHashMap;
+import java.util.Map;
+
+/**
+ * @author Anton Tanasenko
+ */
+public class GoodLifecycleMapping extends AbstractLifecycleMapping
+{
+
+ @Override
+ protected Map<String, String> initPhases()
+ {
+ Map<String, String> phases = new LinkedHashMap<>();
+ phases.put( "validate",
+ "org.apache.maven.its.plugins:mng-5805-pkg-type-mojo-configuration-plugin:2.1-SNAPSHOT:test" );
+ return phases;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/mng5958-extension/src/main/resources/META-INF/plexus/components.xml
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/mng5958-extension/src/main/resources/META-INF/plexus/components.xml b/core-it-support/core-it-plugins/mng5958-extension/src/main/resources/META-INF/plexus/components.xml
new file mode 100644
index 0000000..e61d294
--- /dev/null
+++ b/core-it-support/core-it-plugins/mng5958-extension/src/main/resources/META-INF/plexus/components.xml
@@ -0,0 +1,62 @@
+<?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.
+-->
+<component-set>
+ <components>
+
+ <component>
+ <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
+ <role-hint>mng5958-good</role-hint>
+ <implementation>org.apache.maven.its.mng5958.GoodLifecycleMapping</implementation>
+ </component>
+
+ <component>
+ <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
+ <role-hint>mng5958</role-hint>
+ <implementation>
+ org.apache.maven.artifact.handler.DefaultArtifactHandler
+ </implementation>
+ <configuration>
+ <extension>zip</extension>
+ <type>mng5858-good</type>
+ <packaging>mng5858-good</packaging>
+ </configuration>
+ </component>
+
+ <component>
+ <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
+ <role-hint>mng5958-bad</role-hint>
+ <implementation>org.apache.maven.its.mng5958.BadLifecycleMapping</implementation>
+ </component>
+
+ <component>
+ <role>org.apache.maven.artifact.handler.ArtifactHandler</role>
+ <role-hint>mng5958-bad</role-hint>
+ <implementation>
+ org.apache.maven.artifact.handler.DefaultArtifactHandler
+ </implementation>
+ <configuration>
+ <extension>zip</extension>
+ <type>mng5858-bad</type>
+ <packaging>mng5858-bad</packaging>
+ </configuration>
+ </component>
+
+ </components>
+</component-set>
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/2fd74ac6/core-it-support/core-it-plugins/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-support/core-it-plugins/pom.xml b/core-it-support/core-it-plugins/pom.xml
index 83b5f79..c301aae 100644
--- a/core-it-support/core-it-plugins/pom.xml
+++ b/core-it-support/core-it-plugins/pom.xml
@@ -79,8 +79,10 @@ under the License.
<module>maven-it-plugin-plexus-lifecycle</module>
<module>maven-it-plugin-settings</module>
<module>mng5805-extension</module>
+ <module>mng5805-extension2</module>
<module>mng5805-plugin</module>
<module>mng5805-plugin-dep</module>
+ <module>mng5958-extension</module>
</modules>
<scm>
[2/3] maven-integration-testing git commit: [MNG-6155] The mirror's
id is used when comparing the origin so use the same id as when resolving the
extension
Posted by sc...@apache.org.
[MNG-6155] The mirror's id is used when comparing the origin so use the same id as when resolving the extension
Project: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/commit/6c86dc6f
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/6c86dc6f
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/6c86dc6f
Branch: refs/heads/MNG-5958
Commit: 6c86dc6fe8bad24950fa76d295910e7d7e145a21
Parents: ad98af7
Author: Stephen Connolly <st...@gmail.com>
Authored: Fri Jan 13 13:27:41 2017 +0000
Committer: Stephen Connolly <st...@gmail.com>
Committed: Fri Jan 13 13:27:41 2017 +0000
----------------------------------------------------------------------
.../maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java | 2 --
.../src/test/resources/mng-3599-mk2/settings-template.xml | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/6c86dc6f/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
index 0377348..6e9954b 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng3599useHttpProxyForWebDAVMk2Test.java
@@ -152,7 +152,6 @@ public class MavenITmng3599useHttpProxyForWebDAVMk2Test
verifier = newVerifier( testDir.getAbsolutePath() );
- verifier.addCliOption( "--legacy-local-repository" ); // FIXME this is a temporary band-aid MNG-6155
verifier.addCliOption( "--settings" );
verifier.addCliOption( "settings.xml" );
verifier.addCliOption( "-X" );
@@ -195,7 +194,6 @@ public class MavenITmng3599useHttpProxyForWebDAVMk2Test
verifier = newVerifier( testDir.getAbsolutePath() );
- verifier.addCliOption( "--legacy-local-repository" ); // FIXME this is a temporary band-aid MNG-6155
verifier.addCliOption( "--settings" );
verifier.addCliOption( "settings.xml" );
verifier.addCliOption( "-X" );
http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/6c86dc6f/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml b/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
index 809db8f..257b399 100644
--- a/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
+++ b/core-it-suite/src/test/resources/mng-3599-mk2/settings-template.xml
@@ -1,7 +1,7 @@
<settings>
<mirrors>
<mirror>
- <id>test-mirror</id>
+ <id>central</id>
<url>@protocol@://www.example.com/</url>
<mirrorOf>*</mirrorOf>
</mirror>