Package org.springframework.xd.test.fixtures

Examples of org.springframework.xd.test.fixtures.PollingMailSource


*/
public class MailCommandTests extends AbstractStreamIntegrationTest {

  @Test
  public void testImapPoll() throws Exception {
    PollingMailSource pollingMailSource = newPollingMailSource();
    FileSink fileSink = newFileSink().binary(true);

    pollingMailSource.ensureStarted();

    stream().create(generateStreamName(), "%s | %s", pollingMailSource, fileSink);

    pollingMailSource.sendEmail("from@foo.com", "The Subject", "My body is slim!");

    assertThat(fileSink, eventually(hasContentsThat(equalTo("My body is slim!\r\n"))));
  }
View Full Code Here


    disposables.add(tailSource);
    return tailSource;
  }

  protected PollingMailSource newPollingMailSource() {
    PollingMailSource pollingMailSource = new PollingMailSource();
    disposables.add(pollingMailSource);
    return pollingMailSource;
  }
View Full Code Here

TOP

Related Classes of org.springframework.xd.test.fixtures.PollingMailSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.