diff --git a/0001-Maven-3.patch b/0001-Maven-3.patch new file mode 100644 index 0000000..0c5b003 --- /dev/null +++ b/0001-Maven-3.patch @@ -0,0 +1,34 @@ +From 89e2e52cc4f481dede63fe32381f7862cd2a6b69 Mon Sep 17 00:00:00 2001 +From: Michael Simacek +Date: Thu, 5 May 2016 11:20:48 +0200 +Subject: [PATCH 1/2] Maven 3 + +--- + .../java/org/apache/maven/plugin/surefire/SurefireHelper.java | 11 +---------- + 1 file changed, 1 insertion(+), 10 deletions(-) + +diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java +index a4319bc..32ccf34 100644 +--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java ++++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java +@@ -162,16 +162,7 @@ public final class SurefireHelper + private static String getFailureBehavior( MavenExecutionRequest request ) + throws NoSuchMethodException, InvocationTargetException, IllegalAccessException + { +- try +- { +- return request.getFailureBehavior(); +- } +- catch ( NoSuchMethodError e ) +- { +- return (String) request.getClass() +- .getMethod( "getReactorFailureBehavior" ) +- .invoke( request ); +- } ++ return request.getReactorFailureBehavior(); + } + + } +-- +2.5.5 + diff --git a/0002-Fix-test-with-doxia-1.7.patch b/0002-Fix-test-with-doxia-1.7.patch new file mode 100644 index 0000000..17f2876 --- /dev/null +++ b/0002-Fix-test-with-doxia-1.7.patch @@ -0,0 +1,51 @@ +From 2ba046249b2d31d91949aafba8561b8412c0434b Mon Sep 17 00:00:00 2001 +From: Michael Simacek +Date: Thu, 5 May 2016 11:19:09 +0200 +Subject: [PATCH 2/2] Fix test with doxia-1.7 + +--- + maven-surefire-report-plugin/pom.xml | 9 +++++++-- + .../maven/plugins/surefire/report/SurefireReportGenerator.java | 2 +- + 2 files changed, 8 insertions(+), 3 deletions(-) + +diff --git a/maven-surefire-report-plugin/pom.xml b/maven-surefire-report-plugin/pom.xml +index e7c48a7..880e211 100644 +--- a/maven-surefire-report-plugin/pom.xml ++++ b/maven-surefire-report-plugin/pom.xml +@@ -86,12 +86,17 @@ + + org.apache.maven.doxia + doxia-sink-api +- 1.6 ++ 1.7 + + + org.apache.maven.doxia + doxia-site-renderer +- 1.6 ++ 1.7 ++ ++ ++ org.apache.maven.doxia ++ doxia-core ++ 1.7 + + + org.codehaus.plexus +diff --git a/maven-surefire-report-plugin/src/main/java/org/apache/maven/plugins/surefire/report/SurefireReportGenerator.java b/maven-surefire-report-plugin/src/main/java/org/apache/maven/plugins/surefire/report/SurefireReportGenerator.java +index a6e49cd..f62fd69 100644 +--- a/maven-surefire-report-plugin/src/main/java/org/apache/maven/plugins/surefire/report/SurefireReportGenerator.java ++++ b/maven-surefire-report-plugin/src/main/java/org/apache/maven/plugins/surefire/report/SurefireReportGenerator.java +@@ -27,8 +27,8 @@ import java.util.Map; + import java.util.ResourceBundle; + import org.apache.maven.doxia.markup.HtmlMarkup; + import org.apache.maven.doxia.sink.Sink; +-import org.apache.maven.doxia.sink.SinkEventAttributeSet; + import org.apache.maven.doxia.sink.SinkEventAttributes; ++import org.apache.maven.doxia.sink.impl.SinkEventAttributeSet; + import org.apache.maven.doxia.util.DoxiaUtils; + import org.apache.maven.reporting.MavenReportException; + +-- +2.5.5 + diff --git a/maven-surefire-maven3.patch b/maven-surefire-maven3.patch deleted file mode 100644 index 8571f65..0000000 --- a/maven-surefire-maven3.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- surefire-2.19/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java~ 2015-10-14 21:15:22.000000000 +0200 -+++ surefire-2.19/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/SurefireHelper.java 2015-10-20 08:53:24.412715344 +0200 -@@ -162,16 +162,7 @@ - private static String getFailureBehavior( MavenExecutionRequest request ) - throws NoSuchMethodException, InvocationTargetException, IllegalAccessException - { -- try -- { -- return request.getFailureBehavior(); -- } -- catch ( NoSuchMethodError e ) -- { -- return (String) request.getClass() -- .getMethod( "getReactorFailureBehavior" ) -- .invoke( request ); -- } -+ return request.getReactorFailureBehavior(); - } - - } diff --git a/maven-surefire.spec b/maven-surefire.spec index a887c68..d7b8a81 100644 --- a/maven-surefire.spec +++ b/maven-surefire.spec @@ -1,6 +1,6 @@ Name: maven-surefire Version: 2.19.1 -Release: 2%{?dist} +Release: 3%{?dist} Epoch: 0 Summary: Test framework project License: ASL 2.0 and CPL @@ -10,7 +10,8 @@ BuildArch: noarch Source0: http://repo2.maven.org/maven2/org/apache/maven/surefire/surefire/%{version}/surefire-%{version}-source-release.zip Source2: http://junit.sourceforge.net/cpl-v10.html -Patch0: maven-surefire-maven3.patch +Patch0: 0001-Maven-3.patch +Patch1: 0002-Fix-test-with-doxia-1.7.patch BuildRequires: maven-local BuildRequires: mvn(com.github.stephenc.jcip:jcip-annotations) @@ -113,7 +114,9 @@ Javadoc for %{name}. %prep %setup -q -n surefire-%{version} cp -p %{SOURCE2} . + %patch0 -p1 +%patch1 -p1 %pom_disable_module surefire-shadefire @@ -158,6 +161,9 @@ cp -p %{SOURCE2} . %doc LICENSE NOTICE cpl-v10.html %changelog +* Thu May 05 2016 Michael Simacek - 0:2.19.1-3 +- Fix FTBFS after doxia 1.7 update + * Thu Feb 04 2016 Fedora Release Engineering - 0:2.19.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild