You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2019/11/20 16:40:45 UTC

[hbase] branch master updated: HBASE-22607. TestExportSnapshotNoCluster fails intermittently

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

stack pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hbase.git


View the commit online:
https://github.com/apache/hbase/commit/96fd75bd0e0c6d73b3ed062d64edd28b24760472

The following commit(s) were added to refs/heads/master by this push:
     new 96fd75b  HBASE-22607. TestExportSnapshotNoCluster fails intermittently
96fd75b is described below

commit 96fd75bd0e0c6d73b3ed062d64edd28b24760472
Author: Mingliang Liu <li...@apache.org>
AuthorDate: Wed Jun 19 15:16:35 2019 -0700

    HBASE-22607. TestExportSnapshotNoCluster fails intermittently
---
 .../hadoop/hbase/snapshot/TestExportSnapshotNoCluster.java       | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotNoCluster.java b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotNoCluster.java
index 8da5805..0340c87 100644
--- a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotNoCluster.java
+++ b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshotNoCluster.java
@@ -17,8 +17,13 @@
  */
 package org.apache.hadoop.hbase.snapshot;
 
+import static org.junit.Assert.assertTrue;
+
+import java.net.URI;
+
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
+import org.apache.hadoop.fs.LocalFileSystem;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hbase.HBaseClassTestRule;
 import org.apache.hadoop.hbase.HBaseCommonTestingUtility;
@@ -64,8 +69,10 @@ public class TestExportSnapshotNoCluster {
 
   @BeforeClass
   public static void setUpBeforeClass() throws Exception {
-    testDir = TEST_UTIL.getDataTestDir();
+    // Make sure testDir is on LocalFileSystem
+    testDir = TEST_UTIL.getDataTestDir().makeQualified(URI.create("file:///"), new Path("/"));
     fs = testDir.getFileSystem(TEST_UTIL.getConfiguration());
+    assertTrue("FileSystem '" + fs + "' is not local", fs instanceof LocalFileSystem);
 
     setUpBaseConf(TEST_UTIL.getConfiguration());
   }