Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit e285bf1

Browse files
committedApr 29, 2025
Fix test by using generic exists command
1 parent 2c9219d commit e285bf1

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed
 

‎service/src/test/java/org/whispersystems/textsecuregcm/storage/MessagesCacheTest.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@
99
import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;
1010
import static org.junit.jupiter.api.Assertions.assertEquals;
1111
import static org.junit.jupiter.api.Assertions.assertFalse;
12-
import static org.junit.jupiter.api.Assertions.assertIterableEquals;
13-
import static org.junit.jupiter.api.Assertions.assertNotNull;
1412
import static org.junit.jupiter.api.Assertions.assertNull;
1513
import static org.junit.jupiter.api.Assertions.assertTimeoutPreemptively;
1614
import static org.junit.jupiter.api.Assertions.assertTrue;
@@ -56,7 +54,6 @@
5654
import java.util.concurrent.TimeUnit;
5755
import java.util.concurrent.atomic.AtomicInteger;
5856
import java.util.stream.Collectors;
59-
import java.util.stream.IntStream;
6057
import org.apache.commons.lang3.ArrayUtils;
6158
import org.apache.commons.lang3.RandomStringUtils;
6259
import org.junit.jupiter.api.AfterEach;
@@ -459,7 +456,7 @@ void testMultiRecipientMessage(final boolean sharedMrmKeyPresent) {
459456
do {
460457
exists = 1 == REDIS_CLUSTER_EXTENSION.getRedisCluster()
461458
.withBinaryCluster(conn ->
462-
conn.sync().hlen(MessagesCache.getMessageQueueKey(destinationServiceId.uuid(), deviceId)));
459+
conn.sync().exists(MessagesCache.getMessageQueueKey(destinationServiceId.uuid(), deviceId)));
463460
} while (exists);
464461
}, "Stale MRM message should be deleted asynchronously");
465462

0 commit comments

Comments
 (0)
Please sign in to comment.