This is an automated email from the ASF dual-hosted git repository.

stevel pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/hadoop.git


The following commit(s) were added to refs/heads/trunk by this push:
     new bd498ba  HADOOP-16669. TestRawLocalFileSystemContract.testPermission 
fails if no native library.
bd498ba is described below

commit bd498bac86f1b38fa39c0b7e928e4664e7936f0f
Author: Steve Loughran <ste...@cloudera.com>
AuthorDate: Tue Oct 29 17:09:26 2019 +0000

    HADOOP-16669. TestRawLocalFileSystemContract.testPermission fails if no 
native library.
    
    Contributed by Steve Loughran.
    
    Change-Id: I622e36f17a63c775c5e33e93b8b26e461d0bc451
---
 .../java/org/apache/hadoop/fs/TestRawLocalFileSystemContract.java     | 4 ++++
 1 file changed, 4 insertions(+)

diff --git 
a/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestRawLocalFileSystemContract.java
 
b/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestRawLocalFileSystemContract.java
index 2e514c4..b51419d 100644
--- 
a/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestRawLocalFileSystemContract.java
+++ 
b/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestRawLocalFileSystemContract.java
@@ -24,12 +24,14 @@ import java.util.regex.Pattern;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.test.GenericTestUtils;
 import org.apache.hadoop.test.StatUtils;
+import org.apache.hadoop.util.NativeCodeLoader;
 import org.apache.hadoop.util.Shell;
 
 import org.junit.Before;
 import org.junit.Test;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
+import static org.junit.Assume.assumeTrue;
 
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -127,6 +129,8 @@ public class TestRawLocalFileSystemContract extends 
FileSystemContractBaseTest {
   @Test
   @SuppressWarnings("deprecation")
   public void testPermission() throws Exception {
+    assumeTrue("No native library",
+        NativeCodeLoader.isNativeCodeLoaded());
     Path testDir = getTestBaseDir();
     String testFilename = "teststat2File";
     Path path = new Path(testDir, testFilename);


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-commits-h...@hadoop.apache.org

Reply via email to