From 5f0503ca2fbfb33b15a707a4b2c46ef62b1592ed Mon Sep 17 00:00:00 2001 From: larsh Date: Mon, 12 Aug 2013 23:57:58 +0000 Subject: [PATCH] HBASE-9146 TestHTablePool hangs when run as part of runMediumTests profile (Rajesh Venkatachalam) git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1513302 13f79535-47bb-0310-9956-ffa450edef68 --- .../hadoop/hbase/client/TestHTablePool.java | 24 +++++++++---------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java index 4c1f5187fc4..322ebaa736d 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestHTablePool.java @@ -20,9 +20,6 @@ package org.apache.hadoop.hbase.client; import java.io.IOException; -import junit.framework.Assert; -import junit.framework.TestCase; - import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.util.Bytes; import org.apache.hadoop.hbase.util.PoolMap.PoolType; @@ -38,22 +35,23 @@ import org.junit.runners.Suite; @Suite.SuiteClasses({TestHTablePool.TestHTableReusablePool.class, TestHTablePool.TestHTableThreadLocalPool.class}) @Category(MediumTests.class) public class TestHTablePool { - private static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); - private final static byte[] TABLENAME = Bytes.toBytes("TestHTablePool"); + private static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); + private final static byte[] TABLENAME = Bytes.toBytes("TestHTablePool"); + + public abstract static class TestHTablePoolType { @BeforeClass public static void setUpBeforeClass() throws Exception { - TEST_UTIL.startMiniCluster(1); - TEST_UTIL.createTable(TABLENAME, HConstants.CATALOG_FAMILY); - } + TEST_UTIL.startMiniCluster(1); + TEST_UTIL.createTable(TABLENAME, HConstants.CATALOG_FAMILY); + } @AfterClass - public static void tearDownAfterClass() throws Exception { - TEST_UTIL.shutdownMiniCluster(); - } + public static void tearDownAfterClass() throws Exception { + TEST_UTIL.shutdownMiniCluster(); + } - public abstract static class TestHTablePoolType extends TestCase { - protected abstract PoolType getPoolType(); + protected abstract PoolType getPoolType(); @Test public void testTableWithStringName() throws Exception {