### Question:
WritableIndexReference extends IndexReference { @Override public IndexWriter getWriter() { return writer; } WritableIndexReference( IndexIdentifier identifier, IndexSearcher searcher, IndexWriter writer ); @Override IndexWriter getWriter(); @Override synchronized void dispose(); @Override boolean checkAndClearStale(); @Override void setStale();  }### Answer:
@Test void useProvidedWriterAsIndexWriter() { assertSame( indexWriter, indexReference.getWriter() ); }