public void testIt() throws ProtocolException, ParseException {
String urlString;
Protocol protocol;
Content content;
Parse parse;
Configuration conf = NutchConfiguration.create();
ParseUtil parser = new ParseUtil(conf);
ProtocolFactory factory = new ProtocolFactory(conf);
for (int i = 0; i < sampleFiles.length; i++) {
urlString = "file:" + sampleDir + fileSeparator + sampleFiles[i];
protocol = factory.getProtocol(urlString);
content = protocol.getProtocolOutput(new Text(urlString),
new CrawlDatum()).getContent();
parse = parser.parseByExtensionId("parse-msexcel", content).get(content.getUrl());
assertTrue(parse.getText().equals(expectedText));
}
}