Package com.dtolabs.rundeck.core.utils

Examples of com.dtolabs.rundeck.core.utils.PartialLineBuffer.readLine()


        assertNull(partialLineBuffer.getPartialLine());

        data = " Test8\rTest9".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test7 Test8", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertEquals("Test9", partialLineBuffer.getPartialLine());
        assertNull(partialLineBuffer.getPartialLine());
    }
View Full Code Here


        data = " Test8\rTest9".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test7 Test8", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertEquals("Test9", partialLineBuffer.getPartialLine());
        assertNull(partialLineBuffer.getPartialLine());
    }

    public void testPartialLineBufferMulti() {
View Full Code Here

        PartialLineBuffer partialLineBuffer = new PartialLineBuffer();
        char[] data = "Test10\nTest11\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\r\nTest11\r\n".toCharArray();
View Full Code Here

        PartialLineBuffer partialLineBuffer = new PartialLineBuffer();
        char[] data = "Test10\nTest11\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\r\nTest11\r\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);
View Full Code Here

        char[] data = "Test10\nTest11\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\r\nTest11\r\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);
View Full Code Here

        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\r\nTest11\r\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\rTest11\r".toCharArray();
View Full Code Here

        data = "Test10\r\nTest11\r\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\rTest11\r".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);
View Full Code Here

        data = "Test10\r\nTest11\r\n".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\rTest11\r".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);
View Full Code Here

        assertNull(partialLineBuffer.getPartialLine());

        data = "Test10\rTest11\r".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.getPartialLine());
        assertNull(partialLineBuffer.getPartialLine());
    }
View Full Code Here

        data = "Test10\rTest11\r".toCharArray();
        partialLineBuffer.addData(data, 0, data.length);

        assertEquals("Test10", partialLineBuffer.readLine());
        assertNull(partialLineBuffer.readLine());
        assertEquals("Test11", partialLineBuffer.getPartialLine());
        assertNull(partialLineBuffer.getPartialLine());
    }

    public void testPartialLineBufferLeftoverCR() {
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.