diff --git a/0003-Port-to-TestNG-6.11.patch b/0003-Port-to-TestNG-7.5.1.patch similarity index 52% rename from 0003-Port-to-TestNG-6.11.patch rename to 0003-Port-to-TestNG-7.5.1.patch index 26678177e9e197e0c836ff5f9ee430b5e8c1e2cd..3b5d5cb9164fe1771535599f5bf280308905fb12 100644 --- a/0003-Port-to-TestNG-6.11.patch +++ b/0003-Port-to-TestNG-7.5.1.patch @@ -1,24 +1,25 @@ -From 73cbf7936466f7e32483b871813a82f214d44b30 Mon Sep 17 00:00:00 2001 -From: Mikolaj Izdebski -Date: Mon, 10 Jul 2017 10:37:50 +0200 -Subject: [PATCH 3/4] Port to TestNG 6.11 +From 34f087f62604117e09c2d7609b0ddcc4af97b2c0 Mon Sep 17 00:00:00 2001 +From: starlet-dx <15929766099@163.com> +Date: Sun, 26 Jan 2025 10:32:40 +0800 +Subject: [PATCH 1/1] Port to TestNG 7.5.1 --- surefire-providers/surefire-testng/pom.xml | 3 +-- .../maven/surefire/testng/conf/AbstractDirectConfigurator.java | 2 +- - 2 files changed, 2 insertions(+), 3 deletions(-) + .../maven/surefire/testng/conf/TestNGMapConfigurator.java | 2 +- + 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/surefire-providers/surefire-testng/pom.xml b/surefire-providers/surefire-testng/pom.xml -index 8aee308..e1b37ea 100644 +index 433b4cc..0c2fe69 100644 --- a/surefire-providers/surefire-testng/pom.xml +++ b/surefire-providers/surefire-testng/pom.xml -@@ -51,8 +51,7 @@ +@@ -49,8 +49,7 @@ org.testng testng - 5.10 - jdk15 -+ 6.11 ++ 7.5.1 provided @@ -26,7 +27,7 @@ diff --git a/surefire-providers/surefire-testng/src/main/java/org/apache/maven/s index c639ce9..3f05eed 100644 --- a/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/AbstractDirectConfigurator.java +++ b/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/AbstractDirectConfigurator.java -@@ -63,7 +63,7 @@ public abstract class AbstractDirectConfigurator +@@ -63,7 +63,7 @@ public void configure( TestNG testng, Map options ) testng.setUseDefaultListeners( false ); configureInstance( testng, options ); // TODO: we should have the Profile so that we can decide if this is needed or not @@ -35,6 +36,19 @@ index c639ce9..3f05eed 100644 } @Override +diff --git a/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/TestNGMapConfigurator.java b/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/TestNGMapConfigurator.java +index c51aca6..8cbc7c7 100755 +--- a/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/TestNGMapConfigurator.java ++++ b/surefire-providers/surefire-testng/src/main/java/org/apache/maven/surefire/testng/conf/TestNGMapConfigurator.java +@@ -68,7 +68,7 @@ public void configure( XmlSuite suite, Map options ) + String parallel = options.get( PARALLEL_PROP ); + if ( parallel != null ) + { +- suite.setParallel( parallel ); ++ suite.setParallel( XmlSuite.ParallelMode.getValidParallel( parallel ) ); + } + } + -- -2.17.1 +2.48.1 diff --git a/maven-surefire.spec b/maven-surefire.spec index 54d9e072faf74398c08c377a8e54968ce8a9ebca..ccca36fac170b7458413cc07068c384b5873922f 100644 --- a/maven-surefire.spec +++ b/maven-surefire.spec @@ -1,7 +1,7 @@ Name: maven-surefire Epoch: 0 Version: 2.22.0 -Release: 7 +Release: 8 Summary: The test framework project of surefire License: ASL 2.0 and CPL URL: http://maven.apache.org/surefire/ @@ -10,7 +10,7 @@ Source0: https://github.com/apache/maven-surefire/archive/surefire-% Source1: http://junit.sourceforge.net/cpl-v10.html Patch0000: 0001-Maven-3.patch Patch0001: 0002-Port-to-current-doxia.patch -Patch0002: 0003-Port-to-TestNG-6.11.patch +Patch0002: 0003-Port-to-TestNG-7.5.1.patch Patch0003: 0004-Port-to-current-maven-shared-utils.patch Patch0004: 0005-Port-to-maven-shared-utils-3.3.3.patch BuildRequires: maven-local mvn(com.google.code.findbugs:jsr305) mvn(commons-io:commons-io) @@ -132,6 +132,9 @@ sed -i /-Xdoclint:all/d pom.xml %doc cpl-v10.html %changelog +* Sun Jan 26 2025 yaoxin <1024769339@qq.com> - 0:2.22.0-8 +- Port to TestNG 7.5.1 + * Thu May 26 2022 yaoxin - 0:2.22.0-7 - maven-surefire compilation fails due to maven-shared-utils update to 3.3.3