### Question:
PubMedIDRetriever { public PubMedIdList importPubMedID(String StudyID) throws IOException { InputStream inOne = openUrl(PUBMED_API + "esearch.fcgi?db=pubmed&retmax=0&usehistory=y&term="+StudyID+"[Secondary%20Source%20ID]"); String resultsUrl = getResultsUrl(inOne); InputStream inTwo = openUrl(PUBMED_API + resultsUrl); Document docTwo = parse(inTwo); return getIdList(docTwo); }  PubMedIdList importPubMedID(String StudyID); static Document parse(InputStream is); static InputStream openUrl(String url); static final int READ_TIMEOUT; static final int CONNECTION_TIMEOUT; static final String PUBMED_API; }### Answer:
@Test public void testImportPubMedID() throws MalformedURLException, IOException { PubMedIdList testPubMedIDs = new PubMedIDRetriever().importPubMedID("NCT00000400"); JUnitUtil.assertAllAndOnly(Collections.singletonList(new PubMedId("19401368")), testPubMedIDs); }
@Test public void testImportPubMedNoID() throws MalformedURLException, IOException { PubMedIdList testPubMedIDs = new PubMedIDRetriever().importPubMedID("NCT"); JUnitUtil.assertAllAndOnly(Collections.emptyList(), testPubMedIDs); }