Skip to content
This repository was archived by the owner on Aug 3, 2022. It is now read-only.

Commit 2d5dc59

Browse files
committed
Fix timestamp test to account for different zones and locales.
1 parent 07f9c2c commit 2d5dc59

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

storage/convert_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,12 @@ var _ = Describe("Conversion", func() {
5454
msg := []byte("Hello, World!")
5555
b := prependTimestamp(now, msg)
5656
et, eb := extractTimestamp(b)
57-
Expect(et).Should(Equal(now))
57+
Expect(et.UnixNano()).Should(Equal(now.UnixNano()))
5858
Expect(bytes.Equal(eb, msg)).Should(BeTrue())
5959

6060
b = prependTimestamp(now, nil)
6161
et, eb = extractTimestamp(b)
62-
Expect(et).Should(Equal(now))
62+
Expect(et.UnixNano()).Should(Equal(now.UnixNano()))
6363
Expect(eb).Should(BeEmpty())
6464
})
6565
})

0 commit comments

Comments
 (0)