You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by hb...@apache.org on 2011/07/19 22:48:54 UTC

svn commit: r1148517 - in /maven/plugins/branches/maven-site-plugin-3.x/src/it: inheritedMenus-m3/ inheritedMenus/ inheritedReports/ inheritedReports/child/

Author: hboutemy
Date: Tue Jul 19 20:48:52 2011
New Revision: 1148517

URL: http://svn.apache.org/viewvc?rev=1148517&view=rev
Log:
[MSITE-595] decoupled menu inheritance test from report inheritance (notice that both are actually failing)

Added:
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties   (with props)
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml   (with props)
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties   (with props)
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml   (with props)
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh   (with props)
Removed:
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus-m3/
Modified:
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/README
    maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/verify.bsh

Modified: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/README
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/README?rev=1148517&r1=1148516&r2=1148517&view=diff
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/README (original)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/README Tue Jul 19 20:48:52 2011
@@ -3,5 +3,3 @@ The projects under parentNotAsRef/ and p
 except for the inheritAsRef parameter in the parent's site.xml.
 
 No tests are run for parentAsRef/, it is only built for comparison.
-
-FIXME: the IT currently fails with m3, see MSITE-595
\ No newline at end of file

Added: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties?rev=1148517&view=auto
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties (added)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties Tue Jul 19 20:48:52 2011
@@ -0,0 +1,2 @@
+# Maven 3 has wrong menu items
+invoker.maven.version = 3.0-

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/invoker.properties
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/verify.bsh
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/verify.bsh?rev=1148517&r1=1148516&r2=1148517&view=diff
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/verify.bsh (original)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedMenus/verify.bsh Tue Jul 19 20:48:52 2011
@@ -137,13 +137,6 @@ try
         result = false;
     }
 
-    File childSummary = new File( childSiteDirectory, "project-summary.html" );
-    if ( !childSummary.exists() || childSummary.isDirectory() )
-    {
-        System.err.println( "no summary file in child or is a directory." );
-        result = false;
-    }
-
 
     // GRANDCHILD
 
@@ -202,13 +195,6 @@ try
         result = false;
     }
 
-    File grandChildScm = new File( grandChildSiteDirectory, "source-repository.html" );
-    if ( !grandChildScm.exists() || grandChildScm.isDirectory() )
-    {
-        System.err.println( "no source-repository file in grandchild or is a directory." );
-        result = false;
-    }
-
 }
 catch ( IOException e )
 {

Added: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml?rev=1148517&view=auto
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml (added)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml Tue Jul 19 20:48:52 2011
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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>
+    <groupId>inheritReports</groupId>
+    <artifactId>parent</artifactId>
+    <version>1.0</version>
+    <relativePath>../pom.xml</relativePath>
+  </parent>
+
+  <artifactId>child</artifactId>
+  <packaging>pom</packaging>
+
+  <name>Child overriding report</name>
+
+  <reporting>
+    <plugins>
+      <plugin>
+        <artifactId>maven-project-info-reports-plugin</artifactId>
+        <version>2.3.1</version>
+        <reportSets>
+          <reportSet>
+            <reports>
+              <report>summary</report>
+            </reports>
+          </reportSet>
+        </reportSets>
+      </plugin>
+    </plugins>
+  </reporting>
+
+</project>

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/child/pom.xml
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties?rev=1148517&view=auto
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties (added)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties Tue Jul 19 20:48:52 2011
@@ -0,0 +1,4 @@
+# Maven 2 & 3 don't handle the test the same way:
+# - Maven 2 adds report: this is the tested behaviour
+# - Maven 3 replaces report: the test fails
+invoker.maven.version = 3.0-

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/invoker.properties
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml?rev=1148517&view=auto
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml (added)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml Tue Jul 19 20:48:52 2011
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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>inheritReports</groupId>
+  <artifactId>parent</artifactId>
+  <version>1.0</version>
+  <packaging>pom</packaging>
+
+  <name>MSITE-595 parent</name>
+
+  <build>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-site-plugin</artifactId>
+          <version>@project.version@</version>
+        </plugin>
+      </plugins>
+    </pluginManagement>
+  </build>
+
+  <reporting>
+    <plugins>
+      <plugin>
+        <artifactId>maven-project-info-reports-plugin</artifactId>
+        <version>2.3.1</version>
+        <reportSets>
+          <reportSet>
+            <reports>
+              <report>index</report>
+            </reports>
+          </reportSet>
+        </reportSets>
+      </plugin>
+    </plugins>
+  </reporting>
+
+  <modules>
+    <module>child</module>
+  </modules>
+
+</project>

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/pom.xml
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh?rev=1148517&view=auto
==============================================================================
--- maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh (added)
+++ maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh Tue Jul 19 20:48:52 2011
@@ -0,0 +1,61 @@
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import java.io.*;
+import org.codehaus.plexus.util.*;
+
+boolean result = true;
+
+try
+{
+    File parentSiteDirectory = new File( basedir, "target/site" );
+    File parentIndex = new File( parentSiteDirectory, "index.html" );
+    if ( !parentIndex.exists() || parentIndex.isDirectory() )
+    {
+        System.err.println( "no index file in parent or is a directory." );
+        result = false;
+    }
+
+    // CHILD
+
+    File childSiteDirectory = new File( basedir, "child/target/site" );
+
+    File childIndex = new File( childSiteDirectory, "index.html" );
+    if ( !childIndex.exists() )
+    {
+        System.err.println( "no index file in child." );
+        result = false;
+    }
+
+    File childIndex = new File( childSiteDirectory, "project-summary.html" );
+    if ( !childIndex.exists() )
+    {
+        System.err.println( "no project-summary file in child." );
+        result = false;
+    }
+
+}
+catch ( IOException e )
+{
+    e.printStackTrace();
+    result = false;
+}
+
+return result;

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/branches/maven-site-plugin-3.x/src/it/inheritedReports/verify.bsh
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision