curator-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From randg...@apache.org
Subject [5/8] curator git commit: test assumed first latch would be leader. Fixed it so that this is so
Date Sat, 26 Sep 2015 00:19:33 GMT
test assumed first latch would be leader. Fixed it so that this is so


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

Branch: refs/heads/CURATOR-3.0
Commit: a9271ff6033557efeda01e4c543d0f840519e64d
Parents: f8f13c2
Author: randgalt <randgalt@apache.org>
Authored: Thu Sep 10 22:37:57 2015 -0500
Committer: randgalt <randgalt@apache.org>
Committed: Thu Sep 10 22:37:57 2015 -0500

----------------------------------------------------------------------
 .../apache/curator/framework/recipes/leader/TestLeaderLatch.java  | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/curator/blob/a9271ff6/curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/TestLeaderLatch.java
----------------------------------------------------------------------
diff --git a/curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/TestLeaderLatch.java
b/curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/TestLeaderLatch.java
index ecaa433..991e6fc 100644
--- a/curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/TestLeaderLatch.java
+++ b/curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/TestLeaderLatch.java
@@ -403,10 +403,9 @@ public class TestLeaderLatch extends BaseClassForTests
                 LeaderLatch latch = new LeaderLatch(client, PATH_NAME);
                 latch.start();
                 latches.add(latch);
+                waitForALeader(latches, timing);
             }
 
-            waitForALeader(latches, timing);
-
             //we need to close a Participant that doesn't be actual leader (first Participant)
nor the last
             latches.get(PARTICIPANT_ID).close();
 


Mime
View raw message