mirror of
https://github.com/redis/go-redis.git
synced 2025-07-22 10:01:50 +03:00
Store time in RFC3339Nano to keep nanoseconds
This commit is contained in:
@ -55,13 +55,14 @@ var _ = Describe("WriteBuffer", func() {
|
||||
})
|
||||
|
||||
It("should append time", func() {
|
||||
err := wr.WriteArgs([]interface{}{time.Unix(1414141414, 0).UTC()})
|
||||
tm := time.Date(2019, 01, 01, 9, 45, 10, 222125, time.UTC)
|
||||
err := wr.WriteArgs([]interface{}{tm})
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
err = wr.Flush()
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
|
||||
Expect(buf.Len()).To(Equal(31))
|
||||
Expect(buf.Len()).To(Equal(41))
|
||||
})
|
||||
|
||||
It("should append marshalable args", func() {
|
||||
|
Reference in New Issue
Block a user