Examples of expectedFileExists()


Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testFail() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceived("Hello World");
        mock.expectedFileExists(FTP_ROOT_DIR + "exist/hello.txt", "Hello World");

        try {
            template.sendBodyAndHeader(getFtpUrl(), "Bye World", Exchange.FILE_NAME, "hello.txt");
            fail("Should have thrown a GenericFileOperationFailedException");
        } catch (GenericFileOperationFailedException e) {
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/sub2/.done/goodday.txt");

        mock.assertIsSatisfied();
    }
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/sub2/.done/goodday.txt");

        mock.assertIsSatisfied();
    }
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/sub/sub2/.done/goodday.txt");

        mock.assertIsSatisfied();
    }

    private void prepareFtpServer() throws Exception {
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedMessageCount(1);
        mock.expectedBodiesReceived("Hello World this file will be moved");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/hello.txt.old");

        mock.assertIsSatisfied();
    }

    private void prepareFtpServer() throws Exception {
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/goodday.txt");

        mock.assertIsSatisfied();
    }
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/goodday.txt");

        mock.assertIsSatisfied();
    }
   
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + "movefile/.done/goodday.txt");

        mock.assertIsSatisfied();
    }
   
    private void prepareFtpServer() throws Exception {
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/goodday.txt");

        mock.assertIsSatisfied();
    }
View Full Code Here

Examples of org.apache.camel.component.mock.MockEndpoint.expectedFileExists()

    @Test
    public void testPollFileAndShouldBeMoved() throws Exception {
        MockEndpoint mock = getMockEndpoint("mock:result");
        mock.expectedBodiesReceivedInAnyOrder("Hello", "Bye", "Goodday");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/hello.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/bye.txt");
        mock.expectedFileExists(FTP_ROOT_DIR + ".done/goodday.txt");

        mock.assertIsSatisfied();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.