Package org.apache.pig.builtin

Examples of org.apache.pig.builtin.ENDSWITH.exec()


   
    @Test
    public void testEndsWith() throws IOException {
        ENDSWITH endsWith = new ENDSWITH();
        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
View Full Code Here


    public void testEndsWith() throws IOException {
        ENDSWITH endsWith = new ENDSWITH();
        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }
View Full Code Here

        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }

    @Test
View Full Code Here

        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }

    @Test
    public void testEqualsIgnoreCase() throws IOException {
        EqualsIgnoreCase equalsIgnoreCase = new EqualsIgnoreCase ();
View Full Code Here

   
    @Test
    public void testEndsWith() throws IOException {
        ENDSWITH endsWith = new ENDSWITH();
        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
View Full Code Here

    public void testEndsWith() throws IOException {
        ENDSWITH endsWith = new ENDSWITH();
        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }
View Full Code Here

        Tuple testTuple1 = Util.buildTuple("foo", "bar");
        assertFalse("String suffix should not match", endsWith.exec(testTuple1));
        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }

    @Test
View Full Code Here

        Tuple testTuple2 = Util.buildTuple("foobaz", "foo");
        assertFalse("String suffix should not match", endsWith.exec(testTuple2));
        Tuple testTuple3 = Util.buildTuple("foobaz", "baz");
        assertTrue("String suffix should match", endsWith.exec(testTuple3));
        Tuple testTuple4 = Util.buildTuple(null, "bar");
        assertNull("Should return null", endsWith.exec(testTuple4));
    }

    @Test
    public void testEqualsIgnoreCase() throws IOException {
        EqualsIgnoreCase equalsIgnoreCase = new EqualsIgnoreCase ();
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.