Fix race condition in `TestLeader_FailedMember`
This commit is contained in:
parent
d6f3dc510c
commit
9b6b75f77c
|
@ -88,10 +88,12 @@ func TestLeader_FailedMember(t *testing.T) {
|
|||
|
||||
// Should be registered
|
||||
state := s1.fsm.State()
|
||||
testutil.WaitForResult(func() (bool, error) {
|
||||
_, found, _ := state.GetNode(c1.config.NodeName)
|
||||
if !found {
|
||||
return found == true, nil
|
||||
}, func(err error) {
|
||||
t.Fatalf("client not registered")
|
||||
}
|
||||
})
|
||||
|
||||
// Should have a check
|
||||
_, checks := state.NodeChecks(c1.config.NodeName)
|
||||
|
|
Loading…
Reference in New Issue