HDFS-5559. Fix TestDatanodeConfig in HDFS-2832. (Contributed by szetszwo)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/HDFS-2832@1544891 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Arpit Agarwal 2013-11-23 23:27:13 +00:00
parent f48ea1b516
commit 81211123d8
2 changed files with 5 additions and 1 deletions

View File

@ -118,3 +118,5 @@ IMPROVEMENTS:
HDFS-5542. Fix TODO and clean up the code in HDFS-2832. (Contributed by
szetszwo)
HDFS-5559. Fix TestDatanodeConfig in HDFS-2832. (Contributed by szetszwo)

View File

@ -20,6 +20,7 @@
import static org.apache.hadoop.hdfs.server.common.Util.fileAsURI;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
import static org.junit.Assume.assumeTrue;
import java.io.File;
@ -82,7 +83,8 @@ public void testDataDirectories() throws IOException {
DataNode dn = null;
try {
dn = DataNode.createDataNode(new String[]{}, conf);
} catch(IOException e) {
fail();
} catch(Exception e) {
// expecting exception here
}
if(dn != null)