mirror of
https://github.com/redis/go-redis.git
synced 2025-07-28 06:42:00 +03:00
Cleanups
This commit is contained in:
@ -727,15 +727,20 @@ var _ = Describe("ClusterClient", func() {
|
||||
|
||||
Eventually(func() int64 {
|
||||
return slave.DBSize().Val()
|
||||
}, 30*time.Second).Should(Equal(int64(0)))
|
||||
}, "30s").Should(Equal(int64(0)))
|
||||
|
||||
return nil
|
||||
})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
state, err := client.LoadState()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
Expect(state.IsConsistent()).To(BeTrue())
|
||||
Eventually(func() bool {
|
||||
state, err = client.LoadState()
|
||||
if err != nil {
|
||||
return false
|
||||
}
|
||||
return state.IsConsistent()
|
||||
}, "30s").Should(BeTrue())
|
||||
|
||||
for _, slave := range state.Slaves {
|
||||
err = slave.Client.ClusterFailover().Err()
|
||||
@ -744,7 +749,7 @@ var _ = Describe("ClusterClient", func() {
|
||||
Eventually(func() bool {
|
||||
state, _ := client.LoadState()
|
||||
return state.IsConsistent()
|
||||
}, 30*time.Second).Should(BeTrue())
|
||||
}, "30s").Should(BeTrue())
|
||||
}
|
||||
})
|
||||
|
||||
|
Reference in New Issue
Block a user