}
public void testLuceneSort() throws IOException
{
IndexReader srcReader=IndexReader.open(_indexDir,true);
try{
List<FacetHandler<?>> facetHandlers = new ArrayList<FacetHandler<?>>();
facetHandlers.add(new SimpleFacetHandler("id"));
BoboIndexReader reader= BoboIndexReader.getInstance(srcReader,facetHandlers, null); // not facet handlers to help
BoboBrowser browser = new BoboBrowser(reader);
BrowseRequest browseRequest = new BrowseRequest();
browseRequest.setCount(10);
browseRequest.setOffset(0);
browseRequest.addSortField(new SortField("date",SortField.STRING));
doTest(browser,browseRequest,7,null,new String[]{"1","3","5","2","4","7","6"});
}
catch(IOException ioe){
if (srcReader!=null){
srcReader.close();
}
throw ioe;
}
}