Skip to content

Commit 2f923f5

Browse files
committed
add test for fix #3183
1 parent 58cc4dd commit 2f923f5

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

tests/integration/server_test.go

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,18 @@ var _ = Describe("Server", func() {
321321
Expect(r.Val()).To(Equal("OK"))
322322
})
323323

324+
FIt("should ConfigSet write-buffer-size large value", func() {
325+
// Test for fix: when setting write-buffer-size value larger than 2147483647,
326+
// the value should not become negative
327+
configSet := client.ConfigSet(ctx, "write-buffer-size", "3000000000")
328+
Expect(configSet.Err()).NotTo(HaveOccurred())
329+
Expect(configSet.Val()).To(Equal("OK"))
330+
331+
configGet := client.ConfigGet(ctx, "write-buffer-size")
332+
Expect(configGet.Err()).NotTo(HaveOccurred())
333+
Expect(configGet.Val()).To(Equal(map[string]string{"write-buffer-size": "3000000000"}))
334+
})
335+
324336
It("should ConfigSet maxmemory", func() {
325337
configGet := client.ConfigGet(ctx, "maxmemory")
326338
Expect(configGet.Err()).NotTo(HaveOccurred())

0 commit comments

Comments
 (0)