From ba54af3318a3584cdf685e6be8b5f668aff8a492 Mon Sep 17 00:00:00 2001 From: Samir Ahmic Date: Thu, 31 Dec 2015 17:02:24 +0100 Subject: [PATCH] HBASE-15062 IntegrationTestMTTR conditionally run some tests. Signed-off-by: Michael Stack --- .../apache/hadoop/hbase/mttr/IntegrationTestMTTR.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/hbase-it/src/test/java/org/apache/hadoop/hbase/mttr/IntegrationTestMTTR.java b/hbase-it/src/test/java/org/apache/hadoop/hbase/mttr/IntegrationTestMTTR.java index bd14c31aaf4..58037d20ab0 100644 --- a/hbase-it/src/test/java/org/apache/hadoop/hbase/mttr/IntegrationTestMTTR.java +++ b/hbase-it/src/test/java/org/apache/hadoop/hbase/mttr/IntegrationTestMTTR.java @@ -19,6 +19,7 @@ package org.apache.hadoop.hbase.mttr; import static org.junit.Assert.assertEquals; +import static org.junit.Assume.assumeFalse; import java.io.IOException; import java.util.ArrayList; @@ -266,6 +267,15 @@ public class IntegrationTestMTTR { loadTool = null; } + + private static boolean tablesOnMaster() { + boolean ret = true; + String value = util.getConfiguration().get("hbase.balancer.tablesOnMaster"); + if( value != null && value.equalsIgnoreCase("none")) { + ret = false; + } + return ret; + } @Test public void testRestartRsHoldingTable() throws Exception { @@ -274,6 +284,7 @@ public class IntegrationTestMTTR { @Test public void testKillRsHoldingMeta() throws Exception { + assumeFalse(tablesOnMaster()); run(new ActionCallable(restartMetaAction), "KillRsHoldingMeta"); }