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 2024/05/04 07:01:14 UTC
(maven) 01/01: [MNG-8084] add system properties to test
This is an automated email from the ASF dual-hosted git repository.
hboutemy pushed a commit to branch MNG-8084_unit-tests
in repository https://gitbox.apache.org/repos/asf/maven.git
commit d1e6b25828b0a1d7ce50466ea93bbe37871dface
Author: Hervé Boutemy <hb...@apache.org>
AuthorDate: Sat May 4 09:00:44 2024 +0200
[MNG-8084] add system properties to test
fixes ./${user.home} directory creation during tests execution
---
.../test/java/org/apache/maven/internal/impl/standalone/ApiRunner.java | 1 +
1 file changed, 1 insertion(+)
diff --git a/maven-api-impl/src/test/java/org/apache/maven/internal/impl/standalone/ApiRunner.java b/maven-api-impl/src/test/java/org/apache/maven/internal/impl/standalone/ApiRunner.java
index 147970d564..2106a03467 100644
--- a/maven-api-impl/src/test/java/org/apache/maven/internal/impl/standalone/ApiRunner.java
+++ b/maven-api-impl/src/test/java/org/apache/maven/internal/impl/standalone/ApiRunner.java
@@ -153,6 +153,7 @@ public class ApiRunner {
super(session, repositorySystem, repositories, resolverRepositories, lookup);
systemProperties = System.getenv().entrySet().stream()
.collect(Collectors.toMap(e -> "env." + e.getKey(), e -> e.getValue()));
+ System.getProperties().forEach((k, v) -> systemProperties.put(k.toString(), v.toString()));
}
@Override