From c6496a70c1b6291ab5ab855039a8a1c0696bca69 Mon Sep 17 00:00:00 2001 From: barshaul Date: Sun, 21 Apr 2024 11:18:15 +0000 Subject: [PATCH] Try to revert test changes --- .../src/test/java/glide/SharedCommandTests.java | 14 ++++++++++---- node/tests/SharedTests.ts | 6 +++--- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/java/integTest/src/test/java/glide/SharedCommandTests.java b/java/integTest/src/test/java/glide/SharedCommandTests.java index 70ef2f2a3c..2970892292 100644 --- a/java/integTest/src/test/java/glide/SharedCommandTests.java +++ b/java/integTest/src/test/java/glide/SharedCommandTests.java @@ -1813,12 +1813,15 @@ public void brpop(BaseClient client) { // nothing popped out assertNull( - client.brpop(new String[] {listKey2}, REDIS_VERSION.isLowerThan("7.0.0") ? 1. : 0.5).get()); + client + .brpop(new String[] {listKey2}, REDIS_VERSION.isLowerThan("7.0.0") ? 1. : 0.0001) + .get()); // Key exists, but it is not a list assertEquals(OK, client.set("foo", "bar").get()); ExecutionException executionException = - assertThrows(ExecutionException.class, () -> client.brpop(new String[] {"foo"}, 0.5).get()); + assertThrows( + ExecutionException.class, () -> client.brpop(new String[] {"foo"}, 0.0001).get()); assertTrue(executionException.getCause() instanceof RequestException); } @@ -1863,12 +1866,15 @@ public void blpop(BaseClient client) { // nothing popped out assertNull( - client.blpop(new String[] {listKey2}, REDIS_VERSION.isLowerThan("7.0.0") ? 1. : 0.5).get()); + client + .blpop(new String[] {listKey2}, REDIS_VERSION.isLowerThan("7.0.0") ? 1. : 0.0001) + .get()); // Key exists, but it is not a list assertEquals(OK, client.set("foo", "bar").get()); ExecutionException executionException = - assertThrows(ExecutionException.class, () -> client.blpop(new String[] {"foo"}, 0.5).get()); + assertThrows( + ExecutionException.class, () -> client.blpop(new String[] {"foo"}, 0.0001).get()); assertTrue(executionException.getCause() instanceof RequestException); } diff --git a/node/tests/SharedTests.ts b/node/tests/SharedTests.ts index f2f20f5d42..cda1f32d1d 100644 --- a/node/tests/SharedTests.ts +++ b/node/tests/SharedTests.ts @@ -2041,14 +2041,14 @@ export function runBaseTests(config: { await client.rpush("brpop-test", ["foo", "bar", "baz"]), ).toEqual(3); // Test basic usage - expect(await client.brpop(["brpop-test"], 0.5)).toEqual([ + expect(await client.brpop(["brpop-test"], 0.1)).toEqual([ "brpop-test", "baz", ]); // Delete all values from list expect(await client.del(["brpop-test"])).toEqual(1); - // Test null return when key doesn't exist - expect(await client.brpop(["brpop-test"], 0.5)).toEqual(null); + // Test null return when key doesn't exis + expect(await client.brpop(["brpop-test"], 0.1)).toEqual(null); }, protocol); }, config.timeout,