Skip to content

Commit 60cfdea

Browse files
committed
[MPIR-453] Replace Commons IO in favor of standard APIs
1 parent 4d94edc commit 60cfdea

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

pom.xml

-6
Original file line numberDiff line numberDiff line change
@@ -428,12 +428,6 @@ under the License.
428428
<artifactId>commons-validator</artifactId>
429429
<version>1.7</version>
430430
</dependency>
431-
<dependency>
432-
<groupId>commons-io</groupId>
433-
<artifactId>commons-io</artifactId>
434-
<version>2.12.0</version>
435-
<scope>test</scope>
436-
</dependency>
437431
</dependencies>
438432

439433
<build>

src/test/java/org/apache/maven/report/projectinfo/ModulesReportTest.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,16 @@
2121
import java.io.File;
2222
import java.lang.reflect.Field;
2323
import java.net.URL;
24+
import java.nio.charset.StandardCharsets;
25+
import java.nio.file.Files;
2426
import java.util.Collections;
2527

2628
import com.meterware.httpunit.GetMethodWebRequest;
2729
import com.meterware.httpunit.TextBlock;
2830
import com.meterware.httpunit.WebConversation;
2931
import com.meterware.httpunit.WebRequest;
3032
import com.meterware.httpunit.WebResponse;
31-
import org.apache.commons.io.FileUtils;
33+
3234
import org.apache.maven.plugin.testing.SilentLog;
3335
import org.apache.maven.report.projectinfo.stubs.SubProject1Stub;
3436
import org.codehaus.plexus.util.ReflectionUtils;
@@ -122,6 +124,6 @@ protected String getPOM() {
122124

123125
assertFalse(
124126
"Variable 'sitePublishLocation' should be interpolated",
125-
FileUtils.readFileToString(getGeneratedReport("modules.html")).contains("sitePublishLocation"));
127+
new String(Files.readAllBytes(getGeneratedReport("modules.html").toPath()), StandardCharsets.UTF_8).contains("sitePublishLocation"));
126128
}
127129
}

0 commit comments

Comments
 (0)