This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-imaging.git
The following commit(s) were added to refs/heads/master by this push:
new cc46423d Reuse FileUtils in tests
cc46423d is described below
commit cc46423daf1e317289e8b39353cb0dc421c463be
Author: Gary Gregory <[email protected]>
AuthorDate: Wed Jul 19 12:18:59 2023 -0400
Reuse FileUtils in tests
---
.../commons/imaging/formats/jpeg/exif/ExifRewriterRoundtripTest.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git
a/src/test/java/org/apache/commons/imaging/formats/jpeg/exif/ExifRewriterRoundtripTest.java
b/src/test/java/org/apache/commons/imaging/formats/jpeg/exif/ExifRewriterRoundtripTest.java
index 866b48dc..dda35ea4 100644
---
a/src/test/java/org/apache/commons/imaging/formats/jpeg/exif/ExifRewriterRoundtripTest.java
+++
b/src/test/java/org/apache/commons/imaging/formats/jpeg/exif/ExifRewriterRoundtripTest.java
@@ -33,6 +33,7 @@ import
org.apache.commons.imaging.formats.tiff.TiffImageMetadata;
import org.apache.commons.imaging.formats.tiff.write.TiffOutputDirectory;
import org.apache.commons.imaging.formats.tiff.write.TiffOutputField;
import org.apache.commons.imaging.formats.tiff.write.TiffOutputSet;
+import org.apache.commons.io.FileUtils;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Disabled;
@@ -87,7 +88,7 @@ public class ExifRewriterRoundtripTest extends ExifBaseTest {
}
private File createTempFile() {
- final String tempDir = System.getProperty("java.io.tmpdir");
+ final String tempDir = FileUtils.getTempDirectoryPath();
final String tempFileName = this.getClass().getName() + "-" +
random.nextLong() + ".tmp";
return new File(tempDir, tempFileName);
}