// get an existing bookmark
Bookmark bmark300 = manager.getBookmark(300);
assertEquals("cnn",bmark300.getTags());
// verify the baseline data
Tag cnnTag = tagDao.findTag("cnn").get(0);
Tag newsTag = tagDao.findTag("news2").get(0);
assertEquals(1,cnnTag.getCount());
assertEquals(0,newsTag.getCount());
UserTag cnnUserTag = tagDao.findUserTag(new User(1),cnnTag).get(0);
assertEquals(1,cnnUserTag.getCount());
assertEquals(0,tagDao.findUserTag(new User(1),newsTag).size());
// rename "cnn" to "news"
boolean okay = manager.renameTag(new User(1),"cnn",new String[]{"breakingnews","cnn","headlines"});
assertTrue(okay);
cnnTag = tagDao.findTag("cnn").get(0);
assertEquals(1,cnnTag.getCount());
Tag breakingnewsTag = tagDao.findTag("breakingnews").get(0);
assertEquals(1,breakingnewsTag.getCount());
Tag headlinesTag = tagDao.findTag("headlines").get(0);
assertEquals(1,headlinesTag.getCount());
cnnUserTag = tagDao.findUserTag(new User(1),cnnTag).get(0);
assertEquals(1,cnnUserTag.getCount());
UserTag breakingnewsUserTag = tagDao.findUserTag(new User(1),breakingnewsTag).get(0);