class TagRelatedTagsTests(WLTestCase):
""" tests the /katalog/category/tag/ page for related tags """
def setUp(self):
WLTestCase.setUp(self)
class TagRelatedTagsTests(WLTestCase):
""" tests the /katalog/category/tag/ page for related tags """
def setUp(self):
WLTestCase.setUp(self)
author = PersonStub(("Common",), "Man")
gchild_info = BookInfoStub(author=author, genre="GchildGenre", epoch='Epoch', kind="Kind",
author = PersonStub(("Common",), "Man")
gchild_info = BookInfoStub(author=author, genre="GchildGenre", epoch='Epoch', kind="Kind",
self.assertFalse('Kind' in [tag.name for tag in cats['kind']],
'filtering tag wrongly included in related')
cats = self.client.get('/katalog/motyw/theme/').context['categories']
self.assertFalse('Theme' in [tag.name for tag in cats['theme']],
'filtering theme wrongly included in related')
self.assertFalse('Kind' in [tag.name for tag in cats['kind']],
'filtering tag wrongly included in related')
cats = self.client.get('/katalog/motyw/theme/').context['categories']
self.assertFalse('Theme' in [tag.name for tag in cats['theme']],
'filtering theme wrongly included in related')
def test_parent_tag_once(self):
""" if parent and descendants have a common tag, count it only once """
def test_parent_tag_once(self):
""" if parent and descendants have a common tag, count it only once """