Forráskód Böngészése

HADOOP-3493. Fix TestStreamingFailure to use FileUtil.fullyDelete to ensure correct cleanup. Contributed by Lohit Vijayarenu.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/core/trunk@663812 13f79535-47bb-0310-9956-ffa450edef68
Arun Murthy 17 éve
szülő
commit
5e3496db0a

+ 3 - 0
CHANGES.txt

@@ -470,6 +470,9 @@ Trunk (unreleased changes)
     spawing only one thread each for the on-disk and in-memory merge.
     (Sharad Agarwal via acmurthy)
 
+    HADOOP-3493. Fix TestStreamingFailure to use FileUtil.fullyDelete to
+    ensure correct cleanup. (Lohit Vijayarenu via acmurthy) 
+
 Release 0.17.0 - 2008-05-18
 
   INCOMPATIBLE CHANGES

+ 2 - 1
src/contrib/streaming/src/test/org/apache/hadoop/streaming/TestStreamingFailure.java

@@ -23,6 +23,7 @@ import java.io.*;
 import java.util.*;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
+import org.apache.hadoop.fs.FileUtil;
 import org.apache.hadoop.fs.Path;
 
 /**
@@ -59,7 +60,7 @@ public class TestStreamingFailure extends TestStreaming
   {
     try {
       try {
-        OUTPUT_DIR.getAbsoluteFile().delete();
+        FileUtil.fullyDelete(OUTPUT_DIR.getAbsoluteFile());
       } catch (Exception e) {
       }