accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ctubb...@apache.org
Subject [6/9] git commit: ACCUMULO-3081 Removed commented-out code
Date Sat, 23 Aug 2014 00:37:57 GMT
ACCUMULO-3081 Removed commented-out code

  The code looked out of date, and did not compile, so I could not leave in the
  unused tests with @Ignore. The tests can be reintroduced later, if needed.


Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo
Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/d61b6944
Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/d61b6944
Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/d61b6944

Branch: refs/heads/master
Commit: d61b6944cccbaa5e57e9d922fd4347522dde9625
Parents: da28b8b
Author: Christopher Tubbs <ctubbsii@apache.org>
Authored: Fri Aug 22 20:12:25 2014 -0400
Committer: Christopher Tubbs <ctubbsii@apache.org>
Committed: Fri Aug 22 20:12:25 2014 -0400

----------------------------------------------------------------------
 .../conf/ServerConfigurationFactoryTest.java    | 49 +++++---------------
 1 file changed, 12 insertions(+), 37 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/d61b6944/server/base/src/test/java/org/apache/accumulo/server/conf/ServerConfigurationFactoryTest.java
----------------------------------------------------------------------
diff --git a/server/base/src/test/java/org/apache/accumulo/server/conf/ServerConfigurationFactoryTest.java
b/server/base/src/test/java/org/apache/accumulo/server/conf/ServerConfigurationFactoryTest.java
index bb89b04..7f07d94 100644
--- a/server/base/src/test/java/org/apache/accumulo/server/conf/ServerConfigurationFactoryTest.java
+++ b/server/base/src/test/java/org/apache/accumulo/server/conf/ServerConfigurationFactoryTest.java
@@ -16,6 +16,17 @@
  */
 package org.apache.accumulo.server.conf;
 
+import static org.easymock.EasyMock.anyObject;
+import static org.easymock.EasyMock.createMock;
+import static org.easymock.EasyMock.endsWith;
+import static org.easymock.EasyMock.eq;
+import static org.easymock.EasyMock.expect;
+import static org.easymock.EasyMock.expectLastCall;
+import static org.easymock.EasyMock.replay;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertSame;
+
 import org.apache.accumulo.core.Constants;
 import org.apache.accumulo.core.client.Instance;
 import org.apache.accumulo.core.conf.AccumuloConfiguration;
@@ -23,14 +34,10 @@ import org.apache.accumulo.core.conf.DefaultConfiguration;
 import org.apache.accumulo.core.conf.SiteConfiguration;
 import org.apache.accumulo.fate.zookeeper.ZooCache;
 import org.apache.accumulo.fate.zookeeper.ZooCacheFactory;
-
 import org.junit.After;
 import org.junit.Before;
 import org.junit.BeforeClass;
 import org.junit.Test;
-import static org.junit.Assert.*;
-import org.easymock.Capture;
-import static org.easymock.EasyMock.*;
 
 public class ServerConfigurationFactoryTest {
   private static final String ZK_HOST = "localhost";
@@ -70,7 +77,7 @@ public class ServerConfigurationFactoryTest {
 
   @After
   public void tearDown() throws Exception {
-    scf.clearCachedConfigurations();
+    ServerConfigurationFactory.clearCachedConfigurations();
   }
 
   private void mockInstanceForConfig() {
@@ -102,7 +109,6 @@ public class ServerConfigurationFactoryTest {
     ready();
     SiteConfiguration c = scf.getSiteConfiguration();
     assertNotNull(c);
-    // TBD: assertTrue(c.getParent() instanceof DefaultConfiguration);
   }
 
   @Test
@@ -111,11 +117,9 @@ public class ServerConfigurationFactoryTest {
     ready();
     AccumuloConfiguration c = scf.getConfiguration();
     assertNotNull(c);
-    // TBD: assertTrue(c.getParent() instanceof SiteConfiguration);
   }
 
   private static final String NSID = "NAMESPACE";
-  private static final String TABLE = "TABLE";
 
   @Test
   public void testGetNamespaceConfiguration() {
@@ -123,37 +127,8 @@ public class ServerConfigurationFactoryTest {
     ready();
     NamespaceConfiguration c = scf.getNamespaceConfiguration(NSID);
     assertEquals(NSID, c.getNamespaceId());
-    // TBD: assertTrue(c.getParent() instanceof AccumuloConfiguration);
 
     assertSame(c, scf.getNamespaceConfiguration(NSID));
   }
 
-  /*
-   * TBD: need to work around Tables.getNamespaceId() call in constructor
-  @Test
-  public void testGetNamespaceConfigurationForTable() {
-    mockInstanceForConfig();
-    ready();
-    NamespaceConfiguration c = scf.getNamespaceConfigurationForTable(TABLE);
-    assertTrue(c instanceof TableParentConfiguration);
-    assertEquals(TABLE, ((TableParentConfiguration) c).getTableId());
-    // TBD: assertTrue(c.getParent() instanceof AccumuloConfiguration);
-
-    assertSame(c, scf.getNamespaceConfigurationForTable(TABLE));
-  }
-  */
-
-  /*
-   * TBD: ditto
-  @Test
-  public void testGetTableConfiguration() {
-    mockInstanceForConfig();
-    ready();
-    TableConfiguration c = scf.getTableConfiguration(TABLE);
-    assertEquals(TABLE, c.getTableId());
-    // TBD: assertTrue(c.getParent() instanceof TableParentConfiguration);
-
-    assertSame(c, scf.getTableConfiguration(TABLE));
-  }
-  */
 }


Mime
View raw message