### Question:
FeedsTools { public static String extractEnclosureUrl(SyndEntry entry) { String enclosureUrl = null; final Iterator<SyndEnclosure> theEnclosures = entry.getEnclosures().iterator(); while (theEnclosures.hasNext() && (enclosureUrl == null)) { final SyndEnclosure anEnclosure = theEnclosures.next(); if (FeedsTools.EXTENSION_MATCHER.matcher(anEnclosure.getUrl()).matches()) { if ((anEnclosure.getType() != null) && anEnclosure.getType().contains("audio")) { enclosureUrl = anEnclosure.getUrl(); } } } return enclosureUrl; }  static String extractEnclosureUrl(SyndEntry entry); static boolean isFeedValid(String url, String username, String password); static TtsLangData extractFeedLanguage(String url); static Set<VAction> getUsedFullActionByType(int type);  }### Answer:
@Test public void extractEnclosureTest() { final SyndEntry entry = new SyndEntryImpl(); entry.setTitle("my entry"); final SyndEnclosure invalidEnclosure = new SyndEnclosureImpl(); invalidEnclosure.setUrl("http: invalidEnclosure.setType("audio/mpeg"); final SyndEnclosure validEnclosure = new SyndEnclosureImpl(); validEnclosure.setUrl("http: validEnclosure.setType("audio/mpeg"); entry.setEnclosures(Arrays.asList(invalidEnclosure, validEnclosure)); Assert.assertEquals("http: }