Ejemplo n.º 1
0
 public void deleteTag(Tag tag) {
   log.info("Deleting tag " + tag.getName());
   handTaggingService.clearTaggingsForTag(tag);
   if (tag.getParent() != null) {
     tag.getParent().getChildren().remove(tag);
   }
   tagDAO.deleteTag(tag);
 }
Ejemplo n.º 2
0
  @Test
  public void rssDescriptionForTagShouldBeSetFromTagDescriptionTextIfAvailable() throws Exception {
    RssUrlBuilder rssUrlBuilder = new RssUrlBuilder(siteInformation);

    Mockito.when(tag.getDescription()).thenReturn("This is a tag about something...");

    assertEquals(tag.getDescription(), rssUrlBuilder.getRssDescriptionForTag(tag));
  }
Ejemplo n.º 3
0
 public void updateTagParent(Tag editTag, Tag parentTag) {
   log.debug("Setting parent tag to: " + parentTag.getName());
   editTag.setParent(parentTag);
   // TODO should now reindex all resources effected by this.
 }