mirror of
https://github.com/redis/go-redis.git
synced 2025-06-14 01:21:30 +03:00
Try to fix flaky test.
This commit is contained in:
@ -254,9 +254,9 @@ func ExamplePubSub_Receive() {
|
|||||||
}
|
}
|
||||||
fmt.Println(n, "clients received message")
|
fmt.Println(n, "clients received message")
|
||||||
|
|
||||||
for {
|
for i := 0; i < 2; i++ {
|
||||||
// ReceiveTimeout is a low level API. Use ReceiveMessage instead.
|
// ReceiveTimeout is a low level API. Use ReceiveMessage instead.
|
||||||
msgi, err := pubsub.ReceiveTimeout(time.Second)
|
msgi, err := pubsub.ReceiveTimeout(5 * time.Second)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user