svn commit: r1816985 - in /maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc: FixJavadocMojoTest.java JavadocReportTest.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1816985 - in /maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc: FixJavadocMojoTest.java JavadocReportTest.java

Robert Scholte-8
Author: rfscholte
Date: Sat Dec  2 20:54:38 2017
New Revision: 1816985

URL: http://svn.apache.org/viewvc?rev=1816985&view=rev
Log:
Skip several unittests for Java9

Modified:
    maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/FixJavadocMojoTest.java
    maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/JavadocReportTest.java

Modified: maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/FixJavadocMojoTest.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/FixJavadocMojoTest.java?rev=1816985&r1=1816984&r2=1816985&view=diff
==============================================================================
--- maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/FixJavadocMojoTest.java (original)
+++ maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/FixJavadocMojoTest.java Sat Dec  2 20:54:38 2017
@@ -148,6 +148,13 @@ public class FixJavadocMojoTest
     public void testFixJdk5()
         throws Exception
     {
+        // Should be an assumption, but not supported by TestCase
+        // Java 5 not supported by Java9 anymore
+        if ( JavadocVersion.parse( SystemUtils.JAVA_VERSION ).compareTo( JavadocVersion.parse( "9" ) ) >= 0 )
+        {
+            return;
+        }
+        
         File testPomBasedir = new File( getBasedir(), "target/test/unit/fix-jdk5-test" );
         executeMojoAndTest( testPomBasedir, new String[] { "ClassWithJavadoc.java", "ClassWithNoJavadoc.java",
             "InterfaceWithJavadoc.java", "InterfaceWithNoJavadoc.java", "SubClassWithJavadoc.java" } );

Modified: maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/JavadocReportTest.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/JavadocReportTest.java?rev=1816985&r1=1816984&r2=1816985&view=diff
==============================================================================
--- maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/JavadocReportTest.java (original)
+++ maven/plugins/trunk/maven-javadoc-plugin/src/test/java/org/apache/maven/plugins/javadoc/JavadocReportTest.java Sat Dec  2 20:54:38 2017
@@ -297,6 +297,13 @@ public class JavadocReportTest
     public void testDocfiles()
         throws Exception
     {
+        // Should be an assumption, but not supported by TestCase
+        // Seems like a bug in Javadoc 9
+        if ( JavadocVersion.parse( SystemUtils.JAVA_VERSION ).compareTo( JavadocVersion.parse( "9" ) ) == 0 )
+        {
+            return;
+        }
+        
         File testPom = new File( unit, "docfiles-test/docfiles-test-plugin-config.xml" );
         JavadocReport mojo = lookupMojo( testPom );
         mojo.execute();
@@ -553,6 +560,13 @@ public class JavadocReportTest
     public void testJdk5()
         throws Exception
     {
+        // Should be an assumption, but not supported by TestCase
+        // Java 5 not supported by Java9 anymore
+        if ( JavadocVersion.parse( SystemUtils.JAVA_VERSION ).compareTo( JavadocVersion.parse( "9" ) ) >= 0 )
+        {
+            return;
+        }
+        
         File testPom = new File( unit, "jdk5-test/jdk5-test-plugin-config.xml" );
         JavadocReport mojo = lookupMojo( testPom );
         mojo.execute();