accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject [1/3] accumulo git commit: ACCUMULO-3871 Range.open does not exist in the guava inherited under m/r
Date Fri, 12 Jun 2015 15:46:26 GMT
Repository: accumulo
Updated Branches:
  refs/heads/master 7b4a3b8ab -> 844166a05


ACCUMULO-3871 Range.open does not exist in the guava inherited under m/r


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

Branch: refs/heads/master
Commit: 9e98508aeb9c5abad839980bb393e25fe6872e04
Parents: 7b4a3b8
Author: Eric C. Newton <eric.newton@gmail.com>
Authored: Fri Jun 12 11:41:36 2015 -0400
Committer: Eric C. Newton <eric.newton@gmail.com>
Committed: Fri Jun 12 11:41:36 2015 -0400

----------------------------------------------------------------------
 .../accumulo/test/functional/WatchTheWatchCountIT.java   | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/9e98508a/test/src/main/java/org/apache/accumulo/test/functional/WatchTheWatchCountIT.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/accumulo/test/functional/WatchTheWatchCountIT.java
b/test/src/main/java/org/apache/accumulo/test/functional/WatchTheWatchCountIT.java
index 07d197d..84b944b 100644
--- a/test/src/main/java/org/apache/accumulo/test/functional/WatchTheWatchCountIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/functional/WatchTheWatchCountIT.java
@@ -27,7 +27,6 @@ import org.junit.Test;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.google.common.collect.Range;
 import com.google.common.net.HostAndPort;
 
 // ACCUMULO-2757 - make sure we don't make too many more watchers
@@ -52,7 +51,8 @@ public class WatchTheWatchCountIT extends ConfigurableMacBase {
     }
     c.tableOperations().list();
     String zooKeepers = c.getInstance().getZooKeepers();
-    final Range<Long> expectedWatcherRange = Range.open(475l, 700l);
+    final long MIN = 475L;
+    final long MAX = 700L;
     long total = 0;
     final HostAndPort hostAndPort = HostAndPort.fromString(zooKeepers);
     for (int i = 0; i < 5; i++) {
@@ -64,17 +64,18 @@ public class WatchTheWatchCountIT extends ConfigurableMacBase {
         String response = new String(buffer, 0, n);
         total = Long.parseLong(response.split(":")[1].trim());
         log.info("Total: {}", total);
-        if (expectedWatcherRange.contains(total)) {
+        if (total > MIN && total < MAX) {
           break;
         }
-        log.debug("Expected number of watchers to be contained in {}, but actually was {}.
Sleeping and retrying", expectedWatcherRange, total);
+        log.debug("Expected number of watchers to be contained in ({}, {}), but actually
was {}. Sleeping and retrying", MIN, MAX, total);
         Thread.sleep(5000);
       } finally {
         socket.close();
       }
     }
 
-    assertTrue("Expected number of watchers to be contained in " + expectedWatcherRange +
", but actually was " + total, expectedWatcherRange.contains(total));
+    assertTrue("Expected number of watchers to be contained in (" + MIN + ", " + MAX + "),
but actually was " + total, total > MIN && total < MAX);
+
   }
 
 }


Mime
View raw message