Skip to content

Commit e839f8e

Browse files
committed
fix test warn, the setex command does not support milliseconds
Signed-off-by: monkey <[email protected]>
1 parent e722f52 commit e839f8e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

commands_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1465,7 +1465,7 @@ var _ = Describe("Commands", func() {
14651465
})
14661466

14671467
It("should SetEX", func() {
1468-
err := client.SetEX(ctx, "key", "hello", 100*time.Millisecond).Err()
1468+
err := client.SetEX(ctx, "key", "hello", 1*time.Second).Err()
14691469
Expect(err).NotTo(HaveOccurred())
14701470

14711471
val, err := client.Get(ctx, "key").Result()
@@ -1474,7 +1474,7 @@ var _ = Describe("Commands", func() {
14741474

14751475
Eventually(func() error {
14761476
return client.Get(ctx, "foo").Err()
1477-
}, "1s", "100ms").Should(Equal(redis.Nil))
1477+
}, "2s", "100ms").Should(Equal(redis.Nil))
14781478
})
14791479

14801480
It("should SetNX", func() {

0 commit comments

Comments
 (0)