### Question:
PubAnnotationProvider implements ExternalSearchProvider<PubAnnotationProviderTraits> { @Override public String getDocumentText(DocumentRepository aDocumentRepository, PubAnnotationProviderTraits aTraits, String aCollectionId, String aDocumentId) { return getSections(aDocumentRepository, aTraits, aCollectionId, aDocumentId).stream() .map(PubAnnotationDocumentSection::getText) .collect(Collectors.joining("\n\n")); }  List<PubAnnotationDocumentHandle> query(PubAnnotationProviderTraits aTraits,
            String aQuery); @Override List<ExternalSearchResult> executeQuery(DocumentRepository aDocumentRepository,
            PubAnnotationProviderTraits aTraits, String aQuery); @Override ExternalSearchResult getDocumentResult(DocumentRepository aRepository,
            PubAnnotationProviderTraits aTraits, String aCollectionId, String aDocumentId); @Override String getDocumentText(DocumentRepository aDocumentRepository,
            PubAnnotationProviderTraits aTraits, String aCollectionId, String aDocumentId); @Override InputStream getDocumentAsStream(DocumentRepository aDocumentRepository,
            PubAnnotationProviderTraits aTraits, String aCollectionId, String aDocumentId); @Override String getDocumentFormat(DocumentRepository aRepository,
            PubAnnotationProviderTraits aTraits, String aCollectionId, String aDocumentId);  }### Answer:
@Test public void thatDocumentTextCanBeRetrieved() throws Exception { String text = sut.getDocumentText(repo, traits, "PMC", "1064873"); assertThat(text).isNotEmpty(); }