mirror of
https://github.com/redis/go-redis.git
synced 2025-07-28 06:42:00 +03:00
feat: check pipeline.Do to prevent confusion with Exec (#2517)
Signed-off-by: monkey92t <golang@88.com>
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
package redis_test
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"strconv"
|
||||
|
||||
. "github.com/bsm/ginkgo/v2"
|
||||
@ -84,6 +85,11 @@ var _ = Describe("pipelining", func() {
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
It("should Exec, not Do", func() {
|
||||
err := pipe.Do(ctx).Err()
|
||||
Expect(err).To(Equal(errors.New("redis: please enter the command to be executed")))
|
||||
})
|
||||
}
|
||||
|
||||
Describe("Pipeline", func() {
|
||||
|
Reference in New Issue
Block a user