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 2014/06/10 14:50:53 UTC

[1/4] git commit: Rename as previous ITs have been named

Repository: maven-integration-testing
Updated Branches:
  refs/heads/master 967a3af9a -> d58940e5e


Rename as previous ITs have been named


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/637d7ad4
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/637d7ad4
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/637d7ad4

Branch: refs/heads/master
Commit: 637d7ad4a01ffa91117ae9d1946ba970fdd8f9e6
Parents: 967a3af
Author: Jason van Zyl <ja...@tesla.io>
Authored: Thu May 29 13:51:50 2014 -0400
Committer: Jason van Zyl <ja...@tesla.io>
Committed: Tue Jun 10 07:16:25 2014 -0400

----------------------------------------------------------------------
 ...enITmng5608ProfileActivationWarningTest.java |   2 +-
 .../mng-5608-profile-activation-warning/pom.xml | 131 +++++++++++++++++++
 .../src/test/resources/mng-5608/pom.xml         | 131 -------------------
 3 files changed, 132 insertions(+), 132 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/637d7ad4/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5608ProfileActivationWarningTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5608ProfileActivationWarningTest.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5608ProfileActivationWarningTest.java
index f80dae3..4cf3c10 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5608ProfileActivationWarningTest.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5608ProfileActivationWarningTest.java
@@ -43,7 +43,7 @@ public class MavenITmng5608ProfileActivationWarningTest
     public void testitMNG5608()
         throws Exception
     {
-        File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5608" );
+        File testDir = ResourceExtractor.simpleExtractResources( getClass(), "/mng-5608-profile-activation-warning" );
 
         Verifier verifier = newVerifier( testDir.getAbsolutePath() );
         verifier.executeGoal( "validate" );

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/637d7ad4/core-it-suite/src/test/resources/mng-5608-profile-activation-warning/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5608-profile-activation-warning/pom.xml b/core-it-suite/src/test/resources/mng-5608-profile-activation-warning/pom.xml
new file mode 100644
index 0000000..29a2ee6
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5608-profile-activation-warning/pom.xml
@@ -0,0 +1,131 @@
+<?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.its.mng5608</groupId>
+  <artifactId>profile-test</artifactId>
+  <version>1</version>
+  <packaging>pom</packaging>
+
+  <name>MNG-5608 - Profile activation warning test when file specification contains ${project.basedir}</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.its.plugins</groupId>
+        <artifactId>maven-it-plugin-touch</artifactId>
+        <version>2.1-SNAPSHOT</version>
+        <executions>
+          <execution>
+            <phase>validate</phase>
+            <goals>
+              <goal>touch</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+
+  <profiles>
+    <!-- ${project.basedir} not supported for profile activation -->
+    <profile>
+      <id>mng-5608-exists-project.basedir</id>
+      <activation>
+        <file>
+          <exists>${project.basedir}/pom.xml</exists>
+        </file>
+      </activation>
+      <build>
+        <plugins>
+          <plugin>
+            <groupId>org.apache.maven.its.plugins</groupId>
+            <artifactId>maven-it-plugin-touch</artifactId>
+            <configuration>
+              <fail>true</fail><!-- this profile should not be activated -->
+            </configuration>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+    <profile>
+      <id>mng-5608-missing-project.basedir</id>
+      <activation>
+        <file>
+          <missing>${project.basedir}/pom.xml</missing>
+        </file>
+      </activation>
+      <build>
+        <plugins>
+          <plugin>
+            <groupId>org.apache.maven.its.plugins</groupId>
+            <artifactId>maven-it-plugin-touch</artifactId>
+            <configuration>
+              <pluginItem>mng-5608-missing-project.basedir</pluginItem>
+            </configuration>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+
+    <!-- for reference: ${basedir} supported for profile activation, see MNG-2363 -->
+    <profile>
+      <id>exists-basedir</id>
+      <activation>
+        <file>
+          <exists>${basedir}/pom.xml</exists>
+        </file>
+      </activation>
+      <build>
+        <plugins>
+          <plugin>
+            <groupId>org.apache.maven.its.plugins</groupId>
+            <artifactId>maven-it-plugin-touch</artifactId>
+            <configuration>
+              <goalItem>exists-basedir</goalItem>
+            </configuration>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+    <profile>
+      <id>missing-basedir</id>
+      <activation>
+        <file>
+          <missing>${basedir}/pom.xml</missing>
+        </file>
+      </activation>
+      <build>
+        <plugins>
+          <plugin>
+            <groupId>org.apache.maven.its.plugins</groupId>
+            <artifactId>maven-it-plugin-touch</artifactId>
+            <configuration>
+              <fail>true</fail><!-- this profile should not be activated -->
+            </configuration>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+  </profiles>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/637d7ad4/core-it-suite/src/test/resources/mng-5608/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5608/pom.xml b/core-it-suite/src/test/resources/mng-5608/pom.xml
deleted file mode 100644
index 29a2ee6..0000000
--- a/core-it-suite/src/test/resources/mng-5608/pom.xml
+++ /dev/null
@@ -1,131 +0,0 @@
-<?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.its.mng5608</groupId>
-  <artifactId>profile-test</artifactId>
-  <version>1</version>
-  <packaging>pom</packaging>
-
-  <name>MNG-5608 - Profile activation warning test when file specification contains ${project.basedir}</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.apache.maven.its.plugins</groupId>
-        <artifactId>maven-it-plugin-touch</artifactId>
-        <version>2.1-SNAPSHOT</version>
-        <executions>
-          <execution>
-            <phase>validate</phase>
-            <goals>
-              <goal>touch</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-
-  <profiles>
-    <!-- ${project.basedir} not supported for profile activation -->
-    <profile>
-      <id>mng-5608-exists-project.basedir</id>
-      <activation>
-        <file>
-          <exists>${project.basedir}/pom.xml</exists>
-        </file>
-      </activation>
-      <build>
-        <plugins>
-          <plugin>
-            <groupId>org.apache.maven.its.plugins</groupId>
-            <artifactId>maven-it-plugin-touch</artifactId>
-            <configuration>
-              <fail>true</fail><!-- this profile should not be activated -->
-            </configuration>
-          </plugin>
-        </plugins>
-      </build>
-    </profile>
-    <profile>
-      <id>mng-5608-missing-project.basedir</id>
-      <activation>
-        <file>
-          <missing>${project.basedir}/pom.xml</missing>
-        </file>
-      </activation>
-      <build>
-        <plugins>
-          <plugin>
-            <groupId>org.apache.maven.its.plugins</groupId>
-            <artifactId>maven-it-plugin-touch</artifactId>
-            <configuration>
-              <pluginItem>mng-5608-missing-project.basedir</pluginItem>
-            </configuration>
-          </plugin>
-        </plugins>
-      </build>
-    </profile>
-
-    <!-- for reference: ${basedir} supported for profile activation, see MNG-2363 -->
-    <profile>
-      <id>exists-basedir</id>
-      <activation>
-        <file>
-          <exists>${basedir}/pom.xml</exists>
-        </file>
-      </activation>
-      <build>
-        <plugins>
-          <plugin>
-            <groupId>org.apache.maven.its.plugins</groupId>
-            <artifactId>maven-it-plugin-touch</artifactId>
-            <configuration>
-              <goalItem>exists-basedir</goalItem>
-            </configuration>
-          </plugin>
-        </plugins>
-      </build>
-    </profile>
-    <profile>
-      <id>missing-basedir</id>
-      <activation>
-        <file>
-          <missing>${basedir}/pom.xml</missing>
-        </file>
-      </activation>
-      <build>
-        <plugins>
-          <plugin>
-            <groupId>org.apache.maven.its.plugins</groupId>
-            <artifactId>maven-it-plugin-touch</artifactId>
-            <configuration>
-              <fail>true</fail><!-- this profile should not be activated -->
-            </configuration>
-          </plugin>
-        </plugins>
-      </build>
-    </profile>
-  </profiles>
-</project>


[2/4] git commit: MNG-5640: IT that verifies that lifecycle participant afterSessionEnd is invoked even with build failure

Posted by jv...@apache.org.
MNG-5640: IT that verifies that lifecycle participant afterSessionEnd is invoked even with build failure

Signed-off-by: Jason van Zyl <ja...@tesla.io>


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/3483c6e1
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/3483c6e1
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/3483c6e1

Branch: refs/heads/master
Commit: 3483c6e1ec499f11becc7899d0a40672b06088b7
Parents: 637d7ad
Author: Tamas Cservenak <ta...@cservenak.net>
Authored: Mon Jun 2 15:41:19 2014 +0200
Committer: Jason van Zyl <ja...@tesla.io>
Committed: Tue Jun 10 07:21:25 2014 -0400

----------------------------------------------------------------------
 .../apache/maven/it/IntegrationTestSuite.java   |  1 +
 ...5640LifecycleParticipantAfterSessionEnd.java | 66 +++++++++++++++++++
 .../basic/pom.xml                               | 48 ++++++++++++++
 .../apache/maven/its/mng5640/FailingTest.java   | 18 +++++
 .../extension/pom.xml                           | 69 ++++++++++++++++++++
 .../LifecycleParticipantImpl.java               | 69 ++++++++++++++++++++
 6 files changed, 271 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/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 72bc030..b229581 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,6 +106,7 @@ public class IntegrationTestSuite
         // -------------------------------------------------------------------------------------------------------------
         // suite.addTestSuite( MavenIT0108SnapshotUpdateTest.class ); -- MNG-3137
 
+        suite.addTestSuite( MavenITmng5640LifecycleParticipantAfterSessionEnd.class );
         suite.addTestSuite( MavenITmng5608ProfileActivationWarningTest.class );
         suite.addTestSuite( MavenITmng5591WorkspaceReader.class );
         suite.addTestSuite( MavenITmng5581LifecycleMappingDelegate.class );

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
new file mode 100644
index 0000000..d0151cd
--- /dev/null
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
@@ -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 java.io.File;
+
+import org.apache.maven.it.util.ResourceExtractor;
+
+/**
+ * IT that verifies that lifecycle participant afterSessionEnd
+ * method is invoked even with build failure.
+ */
+public class MavenITmng5640LifecycleParticipantAfterSessionEnd
+    extends AbstractMavenIntegrationTestCase
+{
+    public MavenITmng5640LifecycleParticipantAfterSessionEnd()
+    {
+        super( "[3.2.2,)" );
+    }
+
+    public void test()
+        throws Exception
+    {
+        File testDir =
+            ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
+        File extensionDir = new File( testDir, "extension" );
+        File projectDir = new File( testDir, "basic" );
+
+        Verifier verifier;
+
+        // install the test plugin
+        verifier = newVerifier( extensionDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // build the test project
+        verifier = newVerifier( projectDir.getAbsolutePath(), "remote" );
+        try {
+            verifier.executeGoal("package");
+        } catch (VerificationException e) {
+            // expected, as the build will fail due to always failing UT
+        }
+        verifier.resetStreams();
+        verifier.verifyTextInLog("testApp(org.apache.maven.its.mng5640.FailingTest)");
+
+        verifier.assertFilePresent( "target/afterSessionEnd.txt" );
+    }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
new file mode 100644
index 0000000..fea98e0
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
@@ -0,0 +1,48 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-basic</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
new file mode 100644
index 0000000..3f2dd98
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
@@ -0,0 +1,18 @@
+package org.apache.maven.its.mng5640;
+
+import junit.framework.TestCase;
+
+/**
+ * Always failing UT.
+ */
+public class FailingTest
+    extends TestCase
+{
+  /**
+   * Rigourous Test :-)
+   */
+  public void testApp()
+  {
+    assertTrue( false );
+  }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/pom.xml
new file mode 100644
index 0000000..ec97934
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/pom.xml
@@ -0,0 +1,69 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+  <version>0.1</version>
+
+  <properties>
+    <maven-version>3.2.1</maven-version>
+  </properties>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.apache.maven</groupId>
+      <artifactId>maven-core</artifactId>
+      <version>${maven-version}</version>
+      <scope>provided</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>2.0.2</version>
+        <configuration>
+          <source>1.5</source>
+          <target>1.5</target>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.sonatype.plugins</groupId>
+        <artifactId>sisu-maven-plugin</artifactId>
+        <version>1.1</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>main-index</goal>
+              <goal>test-index</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/3483c6e1/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
new file mode 100644
index 0000000..1dabb2e
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
@@ -0,0 +1,69 @@
+package org.apache.maven.its.mng5640.lifecycleParticipantAfterSession;
+
+/*
+ * 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.FileOutputStream;
+import java.io.IOException;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.inject.Singleton;
+
+import org.apache.maven.AbstractMavenLifecycleParticipant;
+import org.apache.maven.execution.MavenSession;
+import org.apache.maven.project.MavenProject;
+import org.codehaus.plexus.logging.Logger;
+
+@Named
+@Singleton
+public class LifecycleParticipantImpl
+    extends AbstractMavenLifecycleParticipant
+{
+    private final Logger log;
+
+    @Inject
+    public LifecycleParticipantImpl( Logger log )
+    {
+        this.log = log;
+    }
+
+    @Override
+    public void afterSessionEnd( MavenSession session )
+    {
+        MavenProject project = session.getProjects().get( 0 );
+
+        File target = new File( project.getBuild().getDirectory() );
+        File marker = new File( target, "afterSessionEnd.txt" );
+
+        if ( !target.exists() && !target.getParentFile().mkdirs() )
+        {
+            log.error( "Could not create directory " + target );
+        }
+        try
+        {
+            new FileOutputStream( marker ).close();
+        }
+        catch ( IOException e )
+        {
+            log.error( "Could not create marker file " + marker, e );
+        }
+    }
+}


[4/4] git commit: MNG-5640: Enhance IT coverage

Posted by jv...@apache.org.
MNG-5640: Enhance IT coverage

Changes:
- test case for build failure due to UT failure
- test case for build failure due to missing dep
- test case for build error (mojo throwing MojoExecutionEx)
- test case for build error (mojo throwing RuntimeEx)
- checking all participant method invocations, not only afterSessionEnd

Signed-off-by: Jason van Zyl <ja...@tesla.io>


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/33a43e61
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/33a43e61
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/33a43e61

Branch: refs/heads/master
Commit: 33a43e61bcbc5e0d96d6e82ecfd1ce946bd8e400
Parents: 3483c6e
Author: Tamas Cservenak <ta...@cservenak.net>
Authored: Tue Jun 3 10:16:29 2014 +0200
Committer: Jason van Zyl <ja...@tesla.io>
Committed: Tue Jun 10 07:21:25 2014 -0400

----------------------------------------------------------------------
 ...5640LifecycleParticipantAfterSessionEnd.java | 149 ++++++++++++++++++-
 .../badplugin/pom.xml                           |  72 +++++++++
 .../BadMojo.java                                |  38 +++++
 .../BadMojoRt.java                              |  38 +++++
 .../basic/pom.xml                               |  48 ------
 .../apache/maven/its/mng5640/FailingTest.java   |  18 ---
 .../builderror-rt/pom.xml                       |  63 ++++++++
 .../builderror/pom.xml                          |  63 ++++++++
 .../buildfailure-depmissing/pom.xml             |  54 +++++++
 .../apache/maven/its/mng5640/FailingTest.java   |  18 +++
 .../buildfailure/pom.xml                        |  48 ++++++
 .../apache/maven/its/mng5640/FailingTest.java   |  18 +++
 .../LifecycleParticipantImpl.java               |  21 ++-
 13 files changed, 574 insertions(+), 74 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
index d0151cd..fdbd2a7 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
@@ -35,13 +35,16 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
         super( "[3.2.2,)" );
     }
 
-    public void test()
+    /**
+     * IT executing a Maven build that has UT failure. Asserts that afterSessionEnd is still executed.
+     */
+    public void testBuildFailure()
         throws Exception
     {
         File testDir =
             ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
         File extensionDir = new File( testDir, "extension" );
-        File projectDir = new File( testDir, "basic" );
+        File projectDir = new File( testDir, "buildfailure" );
 
         Verifier verifier;
 
@@ -53,14 +56,148 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
 
         // build the test project
         verifier = newVerifier( projectDir.getAbsolutePath(), "remote" );
-        try {
-            verifier.executeGoal("package");
-        } catch (VerificationException e) {
+        try
+        {
+            verifier.executeGoal( "package" );
+            fail( "The build should fail" );
+        }
+        catch (VerificationException e)
+        {
             // expected, as the build will fail due to always failing UT
         }
         verifier.resetStreams();
         verifier.verifyTextInLog("testApp(org.apache.maven.its.mng5640.FailingTest)");
 
+        verifier.assertFilePresent( "target/afterProjectsRead.txt" );
+        // See http://jira.codehaus.org/browse/MNG-5641
+        // verifier.assertFilePresent( "target/afterSessionStart.txt" );
+        verifier.assertFilePresent( "target/afterSessionEnd.txt" );
+    }
+
+    /**
+     * IT executing a Maven build that has missing dependency. Asserts that afterSessionEnd is still executed.
+     */
+    public void testBuildFailureMissingDependency()
+        throws Exception
+    {
+        File testDir =
+            ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
+        File extensionDir = new File( testDir, "extension" );
+        File projectDir = new File( testDir, "buildfailure-depmissing" );
+
+        Verifier verifier;
+
+        // install the test plugin
+        verifier = newVerifier( extensionDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // build the test project
+        verifier = newVerifier( projectDir.getAbsolutePath(), "remote" );
+        try
+        {
+            verifier.executeGoal( "package" );
+            fail( "The build should fail" );
+        }
+        catch (VerificationException e)
+        {
+            // expected, as the build will fail due to always failing UT
+        }
+        verifier.resetStreams();
+
+        verifier.assertFilePresent( "target/afterProjectsRead.txt" );
+        // See http://jira.codehaus.org/browse/MNG-5641
+        // verifier.assertFilePresent( "target/afterSessionStart.txt" );
+        verifier.assertFilePresent( "target/afterSessionEnd.txt" );
+    }
+
+    /**
+     * IT executing a Maven build that has failing Maven plugin. Asserts that afterSessionEnd is still executed.
+     */
+    public void testBuildError()
+        throws Exception
+    {
+        File testDir =
+            ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
+        File extensionDir = new File( testDir, "extension" );
+        File pluginDir = new File( testDir, "badplugin" );
+        File projectDir = new File( testDir, "builderror" );
+
+        Verifier verifier;
+
+        // install the test plugin
+        verifier = newVerifier( extensionDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // install the bad plugin
+        verifier = newVerifier( pluginDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // build the test project
+        verifier = newVerifier( projectDir.getAbsolutePath(), "remote" );
+        try
+        {
+            verifier.executeGoal( "package" );
+            fail( "The build should fail" );
+        }
+        catch ( VerificationException e )
+        {
+            // expected, as the build will fail due to always failing UT
+        }
+        verifier.resetStreams();
+
+        verifier.assertFilePresent( "target/afterProjectsRead.txt" );
+        // See http://jira.codehaus.org/browse/MNG-5641
+        // verifier.assertFilePresent( "target/afterSessionStart.txt" );
         verifier.assertFilePresent( "target/afterSessionEnd.txt" );
     }
-}
+
+    /**
+     * IT executing a Maven build that has failing Maven plugin throwing RuntimeException. Asserts that afterSessionEnd is still executed.
+     */
+    public void testBuildErrorRt()
+        throws Exception
+    {
+        File testDir =
+            ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
+        File extensionDir = new File( testDir, "extension" );
+        File pluginDir = new File( testDir, "badplugin" );
+        File projectDir = new File( testDir, "builderror-rt" );
+
+        Verifier verifier;
+
+        // install the test plugin
+        verifier = newVerifier( extensionDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // install the bad plugin
+        verifier = newVerifier( pluginDir.getAbsolutePath(), "remote" );
+        verifier.executeGoal( "install" );
+        verifier.resetStreams();
+        verifier.verifyErrorFreeLog();
+
+        // build the test project
+        verifier = newVerifier( projectDir.getAbsolutePath(), "remote" );
+        try
+        {
+            verifier.executeGoal( "package" );
+            fail( "The build should fail" );
+        }
+        catch ( VerificationException e )
+        {
+            // expected, as the build will fail due to always failing UT
+        }
+        verifier.resetStreams();
+
+        verifier.assertFilePresent( "target/afterProjectsRead.txt" );
+        // See http://jira.codehaus.org/browse/MNG-5641
+        // verifier.assertFilePresent( "target/afterSessionStart.txt" );
+        verifier.assertFilePresent( "target/afterSessionEnd.txt" );
+    }}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/pom.xml
new file mode 100644
index 0000000..7bcbb90
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/pom.xml
@@ -0,0 +1,72 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
+  <version>0.1</version>
+  <packaging>maven-plugin</packaging>
+
+  <properties>
+    <maven-version>3.2.1</maven-version>
+  </properties>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.apache.maven</groupId>
+      <artifactId>maven-plugin-api</artifactId>
+      <version>${maven-version}</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.maven.plugin-tools</groupId>
+      <artifactId>maven-plugin-annotations</artifactId>
+      <version>3.3</version>
+      <scope>provided</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-plugin-plugin</artifactId>
+        <version>3.3</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>descriptor</goal>
+            </goals>
+          </execution>
+        </executions>
+        <configuration>
+          <!--
+          Works around bug in maven-plugin packaging lifecycle: http://jira.codehaus.org/browse/MNG-5346
+          -->
+          <skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojo.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojo.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojo.java
new file mode 100644
index 0000000..721f86a
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojo.java
@@ -0,0 +1,38 @@
+package org.apache.maven.its.mng5640.lifecycleParticipantAfterSession;
+
+/*
+ * 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.plugin.AbstractMojo;
+import org.apache.maven.plugin.MojoExecutionException;
+import org.apache.maven.plugins.annotations.Mojo;
+
+/**
+ * A bad mojo that fails execution by throwing a MojoExecutionException.
+ */
+@Mojo( name = "bad" )
+public class BadMojo
+    extends AbstractMojo
+{
+    @Override
+    public void execute() throws MojoExecutionException
+    {
+        throw new MojoExecutionException("Am being bad!");
+    }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojoRt.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojoRt.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojoRt.java
new file mode 100644
index 0000000..257a3dd
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/badplugin/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/BadMojoRt.java
@@ -0,0 +1,38 @@
+package org.apache.maven.its.mng5640.lifecycleParticipantAfterSession;
+
+/*
+ * 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.plugin.AbstractMojo;
+import org.apache.maven.plugin.MojoExecutionException;
+import org.apache.maven.plugins.annotations.Mojo;
+
+/**
+ * A bad mojo that fails execution by throwing a runtime exception.
+ */
+@Mojo( name = "badrt" )
+public class BadMojoRt
+    extends AbstractMojo
+{
+    @Override
+    public void execute()
+    {
+        throw new RuntimeException("Am being bad!");
+    }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
deleted file mode 100644
index fea98e0..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/pom.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?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/maven-v4_0_0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-
-  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-  <artifactId>mng-5640-lifecycleParticipant-afterSession-basic</artifactId>
-  <version>0.1</version>
-
-  <dependencies>
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <version>3.8.1</version>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <extensions>
-      <extension>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
-        <version>0.1</version>
-      </extension>
-    </extensions>
-  </build>
-</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
deleted file mode 100644
index 3f2dd98..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/basic/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.apache.maven.its.mng5640;
-
-import junit.framework.TestCase;
-
-/**
- * Always failing UT.
- */
-public class FailingTest
-    extends TestCase
-{
-  /**
-   * Rigourous Test :-)
-   */
-  public void testApp()
-  {
-    assertTrue( false );
-  }
-}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
new file mode 100644
index 0000000..e4448b5
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
@@ -0,0 +1,63 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError-rt</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
+        <version>0.1</version>
+        <executions>
+          <execution>
+            <phase>compile</phase>
+            <goals>
+              <goal>badrt</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
new file mode 100644
index 0000000..458672b
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
@@ -0,0 +1,63 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
+        <version>0.1</version>
+        <executions>
+          <execution>
+            <phase>compile</phase>
+            <goals>
+              <goal>bad</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/pom.xml
new file mode 100644
index 0000000..725b317
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/pom.xml
@@ -0,0 +1,54 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildFailure</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.cstamas.missing</groupId>
+      <artifactId>missing-dependency</artifactId>
+      <version>1.0</version>
+      <scope>compile</scope>
+    </dependency>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
new file mode 100644
index 0000000..3f2dd98
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-depmissing/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
@@ -0,0 +1,18 @@
+package org.apache.maven.its.mng5640;
+
+import junit.framework.TestCase;
+
+/**
+ * Always failing UT.
+ */
+public class FailingTest
+    extends TestCase
+{
+  /**
+   * Rigourous Test :-)
+   */
+  public void testApp()
+  {
+    assertTrue( false );
+  }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
new file mode 100644
index 0000000..121b920
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
@@ -0,0 +1,48 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildFailure</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
new file mode 100644
index 0000000..3f2dd98
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
@@ -0,0 +1,18 @@
+package org.apache.maven.its.mng5640;
+
+import junit.framework.TestCase;
+
+/**
+ * Always failing UT.
+ */
+public class FailingTest
+    extends TestCase
+{
+  /**
+   * Rigourous Test :-)
+   */
+  public void testApp()
+  {
+    assertTrue( false );
+  }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/33a43e61/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
index 1dabb2e..017226a 100644
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/extension/src/main/java/org/apache/maven/its/mng5640/lifecycleParticipantAfterSession/LifecycleParticipantImpl.java
@@ -46,14 +46,31 @@ public class LifecycleParticipantImpl
     }
 
     @Override
+    public void afterProjectsRead( MavenSession session )
+    {
+        dropMarker( session, "afterProjectsRead.txt" );
+    }
+
+    @Override
+    public void afterSessionStart( MavenSession session )
+    {
+        dropMarker( session, "afterSessionStart.txt" );
+    }
+
+    @Override
     public void afterSessionEnd( MavenSession session )
     {
+        dropMarker( session, "afterSessionEnd.txt" );
+    }
+
+    private void dropMarker( MavenSession session, String markerName )
+    {
         MavenProject project = session.getProjects().get( 0 );
 
         File target = new File( project.getBuild().getDirectory() );
-        File marker = new File( target, "afterSessionEnd.txt" );
+        File marker = new File( target, markerName );
 
-        if ( !target.exists() && !target.getParentFile().mkdirs() )
+        if ( !target.exists() && !target.mkdirs() )
         {
             log.error( "Could not create directory " + target );
         }


[3/4] git commit: MNG-6540: renamed resources and test methods

Posted by jv...@apache.org.
MNG-6540: renamed resources and test methods

To better reflect what they actually do

Signed-off-by: Jason van Zyl <ja...@tesla.io>


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/d58940e5
Tree: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/tree/d58940e5
Diff: http://git-wip-us.apache.org/repos/asf/maven-integration-testing/diff/d58940e5

Branch: refs/heads/master
Commit: d58940e5ef3b450b9c93549eb30a067622923441
Parents: 33a43e6
Author: Tamas Cservenak <ta...@cservenak.net>
Authored: Tue Jun 3 10:36:10 2014 +0200
Committer: Jason van Zyl <ja...@tesla.io>
Committed: Tue Jun 10 07:21:25 2014 -0400

----------------------------------------------------------------------
 ...5640LifecycleParticipantAfterSessionEnd.java | 20 +++----
 .../builderror-mojoex/pom.xml                   | 63 ++++++++++++++++++++
 .../builderror-rt/pom.xml                       | 63 --------------------
 .../builderror-runtimeex/pom.xml                | 63 ++++++++++++++++++++
 .../builderror/pom.xml                          | 63 --------------------
 .../buildfailure-utfail/pom.xml                 | 48 +++++++++++++++
 .../apache/maven/its/mng5640/FailingTest.java   | 18 ++++++
 .../buildfailure/pom.xml                        | 48 ---------------
 .../apache/maven/its/mng5640/FailingTest.java   | 18 ------
 9 files changed, 202 insertions(+), 202 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
index fdbd2a7..c253fc2 100644
--- a/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
+++ b/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng5640LifecycleParticipantAfterSessionEnd.java
@@ -24,8 +24,8 @@ import java.io.File;
 import org.apache.maven.it.util.ResourceExtractor;
 
 /**
- * IT that verifies that lifecycle participant afterSessionEnd
- * method is invoked even with build failure.
+ * IT that verifies that lifecycle participant
+ * methods are invoked even with various build failures/errors.
  */
 public class MavenITmng5640LifecycleParticipantAfterSessionEnd
     extends AbstractMavenIntegrationTestCase
@@ -36,15 +36,15 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
     }
 
     /**
-     * IT executing a Maven build that has UT failure. Asserts that afterSessionEnd is still executed.
+     * IT executing a Maven build that has UT failure.
      */
-    public void testBuildFailure()
+    public void testBuildFailureUTFail()
         throws Exception
     {
         File testDir =
             ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
         File extensionDir = new File( testDir, "extension" );
-        File projectDir = new File( testDir, "buildfailure" );
+        File projectDir = new File( testDir, "buildfailure-utfail" );
 
         Verifier verifier;
 
@@ -75,7 +75,7 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
     }
 
     /**
-     * IT executing a Maven build that has missing dependency. Asserts that afterSessionEnd is still executed.
+     * IT executing a Maven build that has missing dependency.
      */
     public void testBuildFailureMissingDependency()
         throws Exception
@@ -113,7 +113,7 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
     }
 
     /**
-     * IT executing a Maven build that has failing Maven plugin. Asserts that afterSessionEnd is still executed.
+     * IT executing a Maven build that has failing Maven plugin.
      */
     public void testBuildError()
         throws Exception
@@ -122,7 +122,7 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
             ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
         File extensionDir = new File( testDir, "extension" );
         File pluginDir = new File( testDir, "badplugin" );
-        File projectDir = new File( testDir, "builderror" );
+        File projectDir = new File( testDir, "builderror-mojoex" );
 
         Verifier verifier;
 
@@ -158,7 +158,7 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
     }
 
     /**
-     * IT executing a Maven build that has failing Maven plugin throwing RuntimeException. Asserts that afterSessionEnd is still executed.
+     * IT executing a Maven build that has failing Maven plugin throwing RuntimeException.
      */
     public void testBuildErrorRt()
         throws Exception
@@ -167,7 +167,7 @@ public class MavenITmng5640LifecycleParticipantAfterSessionEnd
             ResourceExtractor.simpleExtractResources( getClass(), "/mng-5640-lifecycleParticipant-afterSession" );
         File extensionDir = new File( testDir, "extension" );
         File pluginDir = new File( testDir, "badplugin" );
-        File projectDir = new File( testDir, "builderror-rt" );
+        File projectDir = new File( testDir, "builderror-runtimeex" );
 
         Verifier verifier;
 

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-mojoex/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-mojoex/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-mojoex/pom.xml
new file mode 100644
index 0000000..458672b
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-mojoex/pom.xml
@@ -0,0 +1,63 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
+        <version>0.1</version>
+        <executions>
+          <execution>
+            <phase>compile</phase>
+            <goals>
+              <goal>bad</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
deleted file mode 100644
index e4448b5..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-rt/pom.xml
+++ /dev/null
@@ -1,63 +0,0 @@
-<?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/maven-v4_0_0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-
-  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError-rt</artifactId>
-  <version>0.1</version>
-
-  <dependencies>
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <version>3.8.1</version>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <extensions>
-      <extension>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
-        <version>0.1</version>
-      </extension>
-    </extensions>
-    <plugins>
-      <plugin>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
-        <version>0.1</version>
-        <executions>
-          <execution>
-            <phase>compile</phase>
-            <goals>
-              <goal>badrt</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-runtimeex/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-runtimeex/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-runtimeex/pom.xml
new file mode 100644
index 0000000..e4448b5
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror-runtimeex/pom.xml
@@ -0,0 +1,63 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError-rt</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
+        <version>0.1</version>
+        <executions>
+          <execution>
+            <phase>compile</phase>
+            <goals>
+              <goal>badrt</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
deleted file mode 100644
index 458672b..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/builderror/pom.xml
+++ /dev/null
@@ -1,63 +0,0 @@
-<?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/maven-v4_0_0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-
-  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildError</artifactId>
-  <version>0.1</version>
-
-  <dependencies>
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <version>3.8.1</version>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <extensions>
-      <extension>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
-        <version>0.1</version>
-      </extension>
-    </extensions>
-    <plugins>
-      <plugin>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-badplugin</artifactId>
-        <version>0.1</version>
-        <executions>
-          <execution>
-            <phase>compile</phase>
-            <goals>
-              <goal>bad</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/pom.xml
new file mode 100644
index 0000000..121b920
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/pom.xml
@@ -0,0 +1,48 @@
+<?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/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildFailure</artifactId>
+  <version>0.1</version>
+
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <extensions>
+      <extension>
+        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
+        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
+        <version>0.1</version>
+      </extension>
+    </extensions>
+  </build>
+</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
new file mode 100644
index 0000000..3f2dd98
--- /dev/null
+++ b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure-utfail/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
@@ -0,0 +1,18 @@
+package org.apache.maven.its.mng5640;
+
+import junit.framework.TestCase;
+
+/**
+ * Always failing UT.
+ */
+public class FailingTest
+    extends TestCase
+{
+  /**
+   * Rigourous Test :-)
+   */
+  public void testApp()
+  {
+    assertTrue( false );
+  }
+}

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
deleted file mode 100644
index 121b920..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/pom.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?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/maven-v4_0_0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-
-  <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-  <artifactId>mng-5640-lifecycleParticipant-afterSession-buildFailure</artifactId>
-  <version>0.1</version>
-
-  <dependencies>
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <version>3.8.1</version>
-      <scope>test</scope>
-    </dependency>
-  </dependencies>
-
-  <build>
-    <extensions>
-      <extension>
-        <groupId>org.apache.maven.its.mng5640.lifecycleParticipantAfterSession</groupId>
-        <artifactId>mng-5640-lifecycleParticipant-afterSession-extension</artifactId>
-        <version>0.1</version>
-      </extension>
-    </extensions>
-  </build>
-</project>

http://git-wip-us.apache.org/repos/asf/maven-integration-testing/blob/d58940e5/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
----------------------------------------------------------------------
diff --git a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java b/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
deleted file mode 100644
index 3f2dd98..0000000
--- a/core-it-suite/src/test/resources/mng-5640-lifecycleParticipant-afterSession/buildfailure/src/test/java/org/apache/maven/its/mng5640/FailingTest.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.apache.maven.its.mng5640;
-
-import junit.framework.TestCase;
-
-/**
- * Always failing UT.
- */
-public class FailingTest
-    extends TestCase
-{
-  /**
-   * Rigourous Test :-)
-   */
-  public void testApp()
-  {
-    assertTrue( false );
-  }
-}