diff --git a/spring-data-redis/src/test/java/org/springframework/data/keyvalue/redis/connection/AbstractConnectionIntegrationTests.java b/spring-data-redis/src/test/java/org/springframework/data/keyvalue/redis/connection/AbstractConnectionIntegrationTests.java index b9f311745..79266a5ec 100644 --- a/spring-data-redis/src/test/java/org/springframework/data/keyvalue/redis/connection/AbstractConnectionIntegrationTests.java +++ b/spring-data-redis/src/test/java/org/springframework/data/keyvalue/redis/connection/AbstractConnectionIntegrationTests.java @@ -189,7 +189,7 @@ public abstract class AbstractConnectionIntegrationTests { } // pub sub test - + @Test public void testPubSub() throws Exception { final BlockingDeque queue = new LinkedBlockingDeque(); @@ -243,6 +243,7 @@ public abstract class AbstractConnectionIntegrationTests { assertEquals(3, queue.size()); } + @Test public void testPubSubWithNamedChannels() { final byte[] expectedChannel = "channel1".getBytes(); final byte[] expectedMessage = "msg".getBytes(); @@ -261,7 +262,7 @@ public abstract class AbstractConnectionIntegrationTests { public void run() { // sleep 1 second to let the registration happen try { - Thread.currentThread().sleep(1000); + Thread.currentThread().sleep(2000); } catch (InterruptedException ex) { throw new RuntimeException(ex); } @@ -279,6 +280,7 @@ public abstract class AbstractConnectionIntegrationTests { connection.subscribe(listener, expectedChannel); } + @Test public void testPubSubWithPatterns() { final byte[] expectedPattern = "channel*".getBytes(); final byte[] expectedMessage = "msg".getBytes(); @@ -298,7 +300,7 @@ public abstract class AbstractConnectionIntegrationTests { public void run() { // sleep 1 second to let the registration happen try { - Thread.currentThread().sleep(1000); + Thread.currentThread().sleep(1500); } catch (InterruptedException ex) { throw new RuntimeException(ex); }