1
0
mirror of https://github.com/redis/go-redis.git synced 2025-07-28 06:42:00 +03:00

Convert bytes to string in Cmd.

This commit is contained in:
Vladimir Mihailenco
2016-04-12 19:41:56 +03:00
parent 889409de38
commit 818785577e
3 changed files with 16 additions and 7 deletions

View File

@ -128,11 +128,15 @@ var _ = Describe("Client", func() {
Expect(db2.Close()).NotTo(HaveOccurred())
})
It("should process custom commands", func() {
It("processes custom commands", func() {
cmd := redis.NewCmd("PING")
client.Process(cmd)
// Flush buffers.
Expect(client.Echo("hello").Err()).NotTo(HaveOccurred())
Expect(cmd.Err()).NotTo(HaveOccurred())
Expect(cmd.Val()).To(Equal([]byte("PONG")))
Expect(cmd.Val()).To(Equal("PONG"))
})
It("should retry command on network error", func() {