Pipe pipe = new Pipe( "count" );
pipe = new Each( pipe, new Fields( 1 ), new Identity(), new Fields( 2 ) ); // in:second out:all
pipe = new Each( pipe, new Fields( 0 ), new Identity( new Fields( "_all" ) ), new Fields( 1 ) ); // in:all out:_all
pipe = new GroupBy( pipe, new Fields( 0 ) ); // in:_all out:_all
pipe = new Every( pipe, new Fields( 0 ), new Count(), new Fields( 0, 1 ) ); // in:_all out:_all,count
List steps = getPlatform().getFlowConnector().connect( sources, sinks, pipe ).getFlowSteps();
assertEquals( "wrong size", 1, steps.size() );