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

commit 49fc64ed628301b9748e956831aeb1451d52c776
Author: Gary Gregory <garydgreg...@gmail.com>
AuthorDate: Fri Jun 23 16:26:15 2023 -0400

    [hdfs] Throw a specialized RuntimeException instead of
    RuntimeException
---
 .../org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTest.java    | 2 +-
 .../apache/commons/vfs2/provider/hdfs/HdfsFileProviderTestCase.java    | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git 
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTest.java
 
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTest.java
index 7a02222c..ad6d8e36 100644
--- 
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTest.java
+++ 
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTest.java
@@ -99,7 +99,7 @@ public class HdfsFileProviderTest {
             final int newPermission = 0777 ^ umask;
             conf2.set("dfs.datanode.data.dir.perm", String.format("%03o", 
newPermission));
         } catch (final Exception e) {
-            throw new RuntimeException("Error getting umask from O/S", e);
+            throw new IllegalStateException("Error getting umask from O/S", e);
         }
     }
 
diff --git 
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTestCase.java
 
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTestCase.java
index 8dee5b0b..7e8b9e4a 100644
--- 
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTestCase.java
+++ 
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/hdfs/HdfsFileProviderTestCase.java
@@ -20,6 +20,7 @@ import static 
org.apache.commons.vfs2.VfsTestUtils.getTestDirectoryFile;
 
 import java.io.File;
 import java.io.IOException;
+import java.io.UncheckedIOException;
 
 import org.apache.commons.io.FileUtils;
 import org.apache.commons.vfs2.AbstractProviderTestConfig;
@@ -99,7 +100,7 @@ public class HdfsFileProviderTestCase extends 
AbstractProviderTestConfig {
                 cluster = new MiniDFSCluster(PORT, conf, 1, true, true, true, 
null, null, null, null);
                 cluster.waitActive();
             } catch (final IOException e) {
-                throw new RuntimeException("Error setting up mini cluster", e);
+                throw new UncheckedIOException("Error setting up mini 
cluster", e);
             }
             hdfs = cluster.getFileSystem();
 

Reply via email to