def test_similar_pages(self): titles = [ u'hello', u'Low', u'hallow', u'what the hell', ] actual = WikiPage._similar_titles(titles, u'lo') expected = { u'startswiths': [u'Low'], u'endswiths': [u'hello'], u'contains': [u'hallow'], } self.assertEqual(expected, actual)
def test_similar_pages(self): titles = [u"hello", u"Low", u"hallow", u"what the hell"] actual = WikiPage._similar_titles(titles, u"lo") expected = {u"startswiths": [u"Low"], u"endswiths": [u"hello"], u"contains": [u"hallow"]} self.assertEqual(expected, actual)