Github user oza commented on a diff in the pull request:

    https://github.com/apache/curator/pull/200#discussion_r102892185
  
    --- Diff: 
curator-recipes/src/test/java/org/apache/curator/framework/recipes/shared/TestSharedCount.java
 ---
    @@ -381,12 +385,122 @@ public void processResult(CuratorFramework client, 
CuratorEvent event) throws Ex
                 }).forPath("/count");
                 flushDone.await(5, TimeUnit.SECONDS);
     
    -            Assert.assertEquals(2, numChangeEvents.get());
    +            // CURATOR-311: when a Curator client's state became 
RECONNECTED, countHasChanged method is called back
    +            // because the Curator client calls 
readValueAndNotifyListenersInBackground in 
SharedValue#ConnectionStateListener#stateChanged.
    +            Assert.assertEquals(numChangeEvents.get(), 3);
    --- End diff --
    
    Minor nits: this line also fixes wrong order of the argument of 
Assert.assertEquals: assertEquals(actual, expected)  is correct one.
    
    To confirm the reason why I changed numChangeEvents' count, please check 
the comment in the test code.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to