Updated Branches: refs/heads/master 97124c4a5 -> 9d22d30c6
ACCUMULO-1745 Fix up another test that wasn't using the nice "new" table name function. Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/9d22d30c Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/9d22d30c Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/9d22d30c Branch: refs/heads/master Commit: 9d22d30c6482c7bceac21bd5933b3594cc59de96 Parents: 97124c4 Author: Josh Elser <els...@apache.org> Authored: Wed Oct 23 18:44:06 2013 -0700 Committer: Josh Elser <els...@apache.org> Committed: Wed Oct 23 18:44:06 2013 -0700 ---------------------------------------------------------------------- .../java/org/apache/accumulo/test/TableOperationsIT.java | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/accumulo/blob/9d22d30c/test/src/test/java/org/apache/accumulo/test/TableOperationsIT.java ---------------------------------------------------------------------- diff --git a/test/src/test/java/org/apache/accumulo/test/TableOperationsIT.java b/test/src/test/java/org/apache/accumulo/test/TableOperationsIT.java index f092bb7..29e1d23 100644 --- a/test/src/test/java/org/apache/accumulo/test/TableOperationsIT.java +++ b/test/src/test/java/org/apache/accumulo/test/TableOperationsIT.java @@ -76,10 +76,11 @@ public class TableOperationsIT { static Connector connector; static TabletClientService.Client client; - final AtomicInteger tableCounter = new AtomicInteger(0); + static AtomicInteger tableCounter; @BeforeClass public static void startUp() throws IOException, AccumuloException, AccumuloSecurityException, TTransportException, InterruptedException { + tableCounter = new AtomicInteger(0); tempFolder.create(); accumuloCluster = new MiniAccumuloCluster(tempFolder.getRoot(), ROOT_PASS); @@ -144,20 +145,22 @@ public class TableOperationsIT { assertTrue(diskUsages.get(0).getUsage() > 0); assertEquals(tableName, diskUsages.get(0).getTables().first()); + String newTable = makeTableName(); + // clone table - connector.tableOperations().clone(tableName, "table2", false, null, null); + connector.tableOperations().clone(tableName, newTable, false, null, null); // verify tables are exactly the same Set<String> tables = new HashSet<String>(); tables.add(tableName); - tables.add("table2"); + tables.add(newTable); diskUsages = connector.tableOperations().getDiskUsage(tables); assertEquals(1, diskUsages.size()); assertEquals(2, diskUsages.get(0).getTables().size()); assertTrue(diskUsages.get(0).getUsage() > 0); connector.tableOperations().compact(tableName, new Text("A"), new Text("z"), true, true); - connector.tableOperations().compact("table2", new Text("A"), new Text("z"), true, true); + connector.tableOperations().compact(newTable, new Text("A"), new Text("z"), true, true); // verify tables have differences diskUsages = connector.tableOperations().getDiskUsage(tables);