You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2020/02/23 21:38:05 UTC

[maven-shared-utils] 01/01: set names on threads

This is an automated email from the ASF dual-hosted git repository.

elharo pushed a commit to branch i803
in repository https://gitbox.apache.org/repos/asf/maven-shared-utils.git

commit 80a39b4913327add99ed059fed285b5f40f53adc
Author: Elliotte Rusty Harold <el...@ibiblio.org>
AuthorDate: Sun Feb 23 16:37:40 2020 -0500

    set names on threads
---
 src/main/java/org/apache/maven/shared/utils/cli/CommandLineUtils.java  | 3 +++
 .../java/org/apache/maven/shared/utils/cli/CommandLineUtilsTest.java   | 1 -
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/maven/shared/utils/cli/CommandLineUtils.java b/src/main/java/org/apache/maven/shared/utils/cli/CommandLineUtils.java
index 3a745ab..c84be9f 100644
--- a/src/main/java/org/apache/maven/shared/utils/cli/CommandLineUtils.java
+++ b/src/main/java/org/apache/maven/shared/utils/cli/CommandLineUtils.java
@@ -277,13 +277,16 @@ public abstract class CommandLineUtils
                     if ( systemIn != null )
                     {
                         inputFeeder = new StreamFeeder( systemIn, p.getOutputStream() );
+                        inputFeeder.setName("StreamFeeder-systemIn");
                         inputFeeder.start();
                     }
 
                     outputPumper = new StreamPumper( p.getInputStream(), systemOut );
+                    outputPumper.setName("StreamPumper-systemOut");
                     outputPumper.start();
 
                     errorPumper = new StreamPumper( p.getErrorStream(), systemErr );
+                    errorPumper.setName("StreamPumper-systemErr");
                     errorPumper.start();
 
                     int returnValue;
diff --git a/src/test/java/org/apache/maven/shared/utils/cli/CommandLineUtilsTest.java b/src/test/java/org/apache/maven/shared/utils/cli/CommandLineUtilsTest.java
index 5b5ec2a..4483527 100644
--- a/src/test/java/org/apache/maven/shared/utils/cli/CommandLineUtilsTest.java
+++ b/src/test/java/org/apache/maven/shared/utils/cli/CommandLineUtilsTest.java
@@ -19,7 +19,6 @@ package org.apache.maven.shared.utils.cli;
  * under the License.
  */
 
-import static org.junit.Assert.assertArrayEquals;
 import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;