!2 Resolve maven-surefire compilation fails
From: @starlet-dx Reviewed-by: @wangchong1995924 Signed-off-by: @wangchong1995924
This commit is contained in:
commit
db181e0bf2
58
0005-Port-to-maven-shared-utils-3.3.3.patch
Normal file
58
0005-Port-to-maven-shared-utils-3.3.3.patch
Normal file
@ -0,0 +1,58 @@
|
||||
From 3b57ce4a3f7117c9750b8846e6a615f6327f0e4e Mon Sep 17 00:00:00 2001
|
||||
From: starlet-dx <15929766099@163.com>
|
||||
Date: Thu, 26 May 2022 09:37:40 +0800
|
||||
Subject: [PATCH 1/1] Port to maven-shared-utils 3.3.3
|
||||
|
||||
---
|
||||
.../DefaultForkConfiguration.java | 28 +++++++++++--------
|
||||
1 file changed, 17 insertions(+), 11 deletions(-)
|
||||
|
||||
diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/DefaultForkConfiguration.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/DefaultForkConfiguration.java
|
||||
index c35d01c..0bf1170 100644
|
||||
--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/DefaultForkConfiguration.java
|
||||
+++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/DefaultForkConfiguration.java
|
||||
@@ -42,6 +42,8 @@
|
||||
import static org.apache.maven.plugin.surefire.util.Relocator.relocate;
|
||||
import static org.apache.maven.surefire.booter.Classpath.join;
|
||||
|
||||
+import org.apache.maven.shared.utils.cli.CommandLineException;
|
||||
+
|
||||
/**
|
||||
* Basic framework which constructs CLI.
|
||||
*
|
||||
@@ -127,17 +129,21 @@ public OutputStreamFlushableCommandline createCommandLine( @Nonnull StartupConfi
|
||||
|
||||
cli.setExecutable( getJdkForTests().getJvmExecutable() );
|
||||
|
||||
- String jvmArgLine = newJvmArgLine( forkNumber );
|
||||
- if ( !jvmArgLine.isEmpty() )
|
||||
- {
|
||||
- cli.createArg()
|
||||
- .setLine( jvmArgLine );
|
||||
- }
|
||||
-
|
||||
- if ( getDebugLine() != null && !getDebugLine().isEmpty() )
|
||||
- {
|
||||
- cli.createArg()
|
||||
- .setLine( getDebugLine() );
|
||||
+ try {
|
||||
+ String jvmArgLine = newJvmArgLine( forkNumber );
|
||||
+ if ( !jvmArgLine.isEmpty() )
|
||||
+ {
|
||||
+ cli.createArg()
|
||||
+ .setLine( jvmArgLine );
|
||||
+ }
|
||||
+
|
||||
+ if ( getDebugLine() != null && !getDebugLine().isEmpty() )
|
||||
+ {
|
||||
+ cli.createArg()
|
||||
+ .setLine( getDebugLine() );
|
||||
+ }
|
||||
+ } catch (CommandLineException ex) {
|
||||
+ throw new SurefireBooterForkException("", ex);
|
||||
}
|
||||
|
||||
resolveClasspath( cli, findStartClass( config ), config );
|
||||
--
|
||||
2.30.0
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
Name: maven-surefire
|
||||
Epoch: 0
|
||||
Version: 2.22.0
|
||||
Release: 6
|
||||
Release: 7
|
||||
Summary: The test framework project of surefire
|
||||
License: ASL 2.0 and CPL
|
||||
URL: http://maven.apache.org/surefire/
|
||||
@ -12,6 +12,7 @@ Patch0000: 0001-Maven-3.patch
|
||||
Patch0001: 0002-Port-to-current-doxia.patch
|
||||
Patch0002: 0003-Port-to-TestNG-6.11.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)
|
||||
BuildRequires: mvn(junit:junit) mvn(org.apache.maven.plugins:maven-dependency-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.doxia:doxia-site-renderer) mvn(org.testng:testng::jdk15:)
|
||||
@ -131,5 +132,8 @@ sed -i /-Xdoclint:all/d pom.xml
|
||||
%doc cpl-v10.html
|
||||
|
||||
%changelog
|
||||
* Thu May 26 2022 yaoxin <yaoxin30@h-partners.com> - 0:2.22.0-7
|
||||
- maven-surefire compilation fails due to maven-shared-utils update to 3.3.3
|
||||
|
||||
* Mon Jun 15 2020 Jeffery.Gao <gaojianxing@huawei.com> - 2.22.0-6
|
||||
- Package init
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user