Added calls to sourceEndpoint.afterPropertiesSet() in tests.

This commit is contained in:
Mark Fisher
2008-07-01 23:31:33 +00:00
parent 570cee8f9b
commit b39865606a
2 changed files with 4 additions and 0 deletions

View File

@@ -43,6 +43,7 @@ public class ByteStreamSourceTests {
MessageChannel channel = new QueueChannel();
ByteStreamSource source = new ByteStreamSource(stream);
SourceEndpoint endpoint = new SourceEndpoint(source, channel);
endpoint.afterPropertiesSet();
endpoint.invoke(new CommandMessage(new PollCommand()));
Message<?> message1 = channel.receive(500);
byte[] payload = (byte[]) message1.getPayload();
@@ -67,6 +68,7 @@ public class ByteStreamSourceTests {
PollingSchedule schedule = new PollingSchedule(1000);
schedule.setInitialDelay(10000);
SourceEndpoint endpoint = new SourceEndpoint(source, channel);
endpoint.afterPropertiesSet();
endpoint.invoke(new CommandMessage(new PollCommand()));
Message<?> message1 = channel.receive(0);
assertEquals(4, ((byte[]) message1.getPayload()).length);
@@ -88,6 +90,7 @@ public class ByteStreamSourceTests {
PollingSchedule schedule = new PollingSchedule(1000);
schedule.setInitialDelay(10000);
SourceEndpoint endpoint = new SourceEndpoint(source, channel);
endpoint.afterPropertiesSet();
endpoint.invoke(new CommandMessage(new PollCommand()));
Message<?> message1 = channel.receive(0);
assertEquals(4, ((byte[]) message1.getPayload()).length);

View File

@@ -44,6 +44,7 @@ public class CharacterStreamSourceTests {
PollingSchedule schedule = new PollingSchedule(1000);
schedule.setInitialDelay(10000);
SourceEndpoint endpoint = new SourceEndpoint(source, channel);
endpoint.afterPropertiesSet();
endpoint.invoke(new CommandMessage(new PollCommand()));
Message<?> message1 = channel.receive(0);
assertEquals("test", message1.getPayload());