MessageListenerContainer must not be initialized twice.
Error when afterPropertiesSet is called more than once. Update documentation and error messages. Original Pull Request: #2256
This commit is contained in:
@@ -105,4 +105,9 @@ class RedisMessageListenerContainerUnitTests {
|
||||
assertThat(container.isRunning()).isFalse();
|
||||
verify(subscriptionMock).close();
|
||||
}
|
||||
|
||||
@Test // GH-964
|
||||
void failsOnDuplicateInit() {
|
||||
assertThatExceptionOfType(IllegalStateException.class).isThrownBy(() -> container.afterPropertiesSet());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user