// Create FileSplit
Path p = new Path(f.toURI().toString());
WikipediaInputSplit split = new WikipediaInputSplit(new FileSplit(p, 0, f.length(), null),0);
// Initialize the RecordReader
AggregatingRecordReader reader = new AggregatingRecordReader();
reader.initialize(split, ctx);
assertTrue("Not enough records returned.", reader.nextKeyValue());
testXML(reader.getCurrentValue(), "A", "B", "G");
assertTrue("Not enough records returned.", reader.nextKeyValue());
testXML(reader.getCurrentValue(), "C", "D", "");
assertTrue("Not enough records returned.", reader.nextKeyValue());
testXML(reader.getCurrentValue(), "", "", "H");
assertTrue("Not enough records returned.", reader.nextKeyValue());
testXML(reader.getCurrentValue(), "E", "F", "");
assertTrue("Not enough records returned.", reader.nextKeyValue());
testXML(reader.getCurrentValue(), "", "", "I");
assertTrue("Too many records returned.", !reader.nextKeyValue());
}