def test_end_of_string(self): self.assertEqual(clean_pattern(ur'ab$'), u'/ab$') self.assertEqual(clean_pattern(ur'ab.$'), u'/ab*')
def clean_equal(self, pattern, result): self.assertEqual(clean_pattern(pattern), '/' + result + '*')
def test_end_of_string(self): self.assertEqual(clean_pattern(r'ab$'), u'/ab$') self.assertEqual(clean_pattern(r'ab.$'), u'/ab*')
def clean_equal(self, pattern, result): self.assertEqual(clean_pattern(pattern), "/" + result + "*")
def test_end_of_string(self): self.assertEqual(clean_pattern(r"ab$"), u"/ab$") self.assertEqual(clean_pattern(r"ab.$"), u"/ab*")