{
RegexParser splitter = new RegexParser( new Fields( "lhs", "rhs" ), "(\\S+)\\s+(\\S+)", new int[]{1, 2} );
Tuple arguments = new Tuple( "foo\tbar" );
Fields resultFields = Fields.size( 2 );
TupleListCollector collector = invokeFunction( splitter, arguments, resultFields );
assertEquals( "wrong size", 1, collector.size() );
Iterator<Tuple> iterator = collector.iterator();
Tuple tuple = iterator.next();
assertEquals( "not equal: tuple.get(0)", "foo", tuple.getObject( 0 ) );
assertEquals( "not equal: tuple.get(1)", "bar", tuple.getObject( 1 ) );