From d25cd61de196c54e833d7a0bfa5dcff3d64a5400 Mon Sep 17 00:00:00 2001 From: Basil Crow Date: Sun, 30 May 2021 10:23:03 -0700 Subject: [PATCH] Stop using deprecated `Util#join` (#150) --- src/main/java/hudson/plugins/jacoco/JacocoPublisher.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/hudson/plugins/jacoco/JacocoPublisher.java b/src/main/java/hudson/plugins/jacoco/JacocoPublisher.java index beb3fc2d..cd2c2b2d 100644 --- a/src/main/java/hudson/plugins/jacoco/JacocoPublisher.java +++ b/src/main/java/hudson/plugins/jacoco/JacocoPublisher.java @@ -4,7 +4,6 @@ import hudson.Extension; import hudson.FilePath; import hudson.Launcher; -import hudson.Util; import hudson.model.Result; import hudson.model.AbstractBuild; import hudson.model.AbstractProject; @@ -26,6 +25,7 @@ import java.util.Collections; import java.util.List; import java.util.Map; +import java.util.stream.Collectors; import jenkins.MasterToSlaveFileCallable; import jenkins.model.Jenkins; @@ -625,7 +625,7 @@ public void perform(@Nonnull Run run, @Nonnull FilePath filePath, @Nonnull logger.println("[JaCoCo plugin] Number of found exec files for pattern " + execPattern + ": " + matchedExecFiles.size()); logger.print("[JaCoCo plugin] Saving matched execfiles: "); reportDir.addExecFiles(matchedExecFiles); - logger.print(" " + Util.join(matchedExecFiles," ")); + logger.print(" " + matchedExecFiles.stream().map(Object::toString).collect(Collectors.joining(" "))); FilePath[] matchedClassDirs = resolveDirPaths(filePath, taskListener, classPattern); logger.print("\n[JaCoCo plugin] Saving matched class directories for class-pattern: " + classPattern + ": "); final String warning = "\n[JaCoCo plugin] WARNING: You are using directory patterns with trailing /, /* or /** . This will most likely" +