cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From slebre...@apache.org
Subject [3/6] git commit: Fix LeaveAndBootstrapTest
Date Tue, 19 Nov 2013 17:27:32 GMT
Fix LeaveAndBootstrapTest


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

Branch: refs/heads/trunk
Commit: eeb8d1bdc6ea67f472bcbc5225cdaca5a3199650
Parents: 445c874
Author: Sylvain Lebresne <sylvain@datastax.com>
Authored: Tue Nov 19 18:05:03 2013 +0100
Committer: Sylvain Lebresne <sylvain@datastax.com>
Committed: Tue Nov 19 18:22:59 2013 +0100

----------------------------------------------------------------------
 .../org/apache/cassandra/service/LeaveAndBootstrapTest.java    | 6 ++++++
 1 file changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/eeb8d1bd/test/unit/org/apache/cassandra/service/LeaveAndBootstrapTest.java
----------------------------------------------------------------------
diff --git a/test/unit/org/apache/cassandra/service/LeaveAndBootstrapTest.java b/test/unit/org/apache/cassandra/service/LeaveAndBootstrapTest.java
index 73abbe2..d385b11 100644
--- a/test/unit/org/apache/cassandra/service/LeaveAndBootstrapTest.java
+++ b/test/unit/org/apache/cassandra/service/LeaveAndBootstrapTest.java
@@ -107,6 +107,8 @@ public class LeaveAndBootstrapTest
                 valueFactory.leaving(Collections.singleton(endpointTokens.get(LEAVING_NODE))));
         assertTrue(tmd.isLeaving(hosts.get(LEAVING_NODE)));
 
+        PendingRangeCalculatorService.instance.blockUntilFinished();
+
         AbstractReplicationStrategy strategy;
         for (String table : Schema.instance.getNonSystemTables())
         {
@@ -232,6 +234,8 @@ public class LeaveAndBootstrapTest
         expectedEndpoints.get("Keyspace4").putAll(new BigIntegerToken("85"), makeAddrs("127.0.0.10",
"127.0.0.1", "127.0.0.2", "127.0.0.3"));
         expectedEndpoints.get("Keyspace4").putAll(new BigIntegerToken("95"), makeAddrs("127.0.0.1",
"127.0.0.2", "127.0.0.3"));
 
+        PendingRangeCalculatorService.instance.blockUntilFinished();
+
         for (Map.Entry<String, AbstractReplicationStrategy> tableStrategy : tableStrategyMap.entrySet())
         {
             String table = tableStrategy.getKey();
@@ -352,6 +356,8 @@ public class LeaveAndBootstrapTest
         expectedEndpoints.get("Keyspace4").get(new BigIntegerToken("75")).removeAll(makeAddrs("127.0.0.10"));
         expectedEndpoints.get("Keyspace4").get(new BigIntegerToken("85")).removeAll(makeAddrs("127.0.0.10"));
 
+        PendingRangeCalculatorService.instance.blockUntilFinished();
+
         for (Map.Entry<String, AbstractReplicationStrategy> tableStrategy : tableStrategyMap.entrySet())
         {
             String table = tableStrategy.getKey();


Mime
View raw message