for(Category category : Category.values()) { // For each Category
String categoryString = category.toString().toLowerCase();
// Add the category, book title input spec with the associated CategoryMapper
for(FileStatus fileStatus: fileSystem.listStatus(new Path(input + "/" + categoryString))) {
job.addInput(fileStatus.getPath(), new HadoopInputFormat(TextInputFormat.class),
new CategoryMapper(category, fileStatus.getPath().getName()));
}
// Add a named output for each category
job.addNamedOutput(categoryString, new TupleSolrOutputFormat(new File("src/test/resources/shakespeare-solr"),
conf), ITuple.class, NullWritable.class);