Fix code smell in test and syslog modules (#2667)
* Fix code smell in test and syslog modules * * Fix code smell in the scripting module
This commit is contained in:
committed by
Gary Russell
parent
12dd73d219
commit
271181247d
@@ -148,8 +148,10 @@ public class MockIntegrationContext implements BeanFactoryAware {
|
||||
}
|
||||
DirectFieldAccessor directFieldAccessor = new DirectFieldAccessor(endpoint);
|
||||
Object targetMessageHandler = directFieldAccessor.getPropertyValue("handler");
|
||||
Assert.notNull(targetMessageHandler, () -> "'handler' must not be null in the: " + endpoint);
|
||||
if (endpoint instanceof ReactiveStreamsConsumer) {
|
||||
Object targetSubscriber = directFieldAccessor.getPropertyValue("subscriber");
|
||||
Assert.notNull(targetSubscriber, () -> "'subscriber' must not be null in the: " + endpoint);
|
||||
this.beans.put(consumerEndpointId, Tuples.of(targetMessageHandler, targetSubscriber));
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user