You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2020/09/26 02:45:15 UTC
[commons-vfs] branch master updated: Try to delete temp files
sooner in the test to help builds from the command line on Windows.
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-vfs.git
The following commit(s) were added to refs/heads/master by this push:
new 625aedf Try to delete temp files sooner in the test to help builds from the command line on Windows.
625aedf is described below
commit 625aedf1d847b840b09c087bee69ec5a5f514f54
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Fri Sep 25 22:45:11 2020 -0400
Try to delete temp files sooner in the test to help builds from the
command line on Windows.
---
.../org/apache/commons/vfs2/impl/test/DefaultFileMonitorTest.java | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/impl/test/DefaultFileMonitorTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/impl/test/DefaultFileMonitorTest.java
index 7c9ee98..9d66ca7 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/impl/test/DefaultFileMonitorTest.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/impl/test/DefaultFileMonitorTest.java
@@ -57,7 +57,9 @@ public class DefaultFileMonitorTest extends AbstractVfsTestCase {
@Override
public void tearDown() throws Exception {
if (testFile != null) {
- testFile.deleteOnExit();
+ if (!testFile.delete()) {
+ testFile.deleteOnExit();
+ }
}
super.tearDown();
}