@After
 public void tearDown() throws Exception {
   super.tearDown();
   if (readerContext != null) {
     readerContext.reader().close();
   }
   writer.close();
 }
 protected AtomicReaderContext refreshReader() throws Exception {
   if (readerContext != null) {
     readerContext.reader().close();
   }
   AtomicReader reader =
       SlowCompositeReaderWrapper.wrap(topLevelReader = DirectoryReader.open(writer, true));
   readerContext = reader.getContext();
   return readerContext;
 }