def test_two_char_not_in(self): """ test two character not in string """ values = ('aa', 'abc') self.assertEqual(get_match_with_iteration(*values), False) self.assertEqual(get_match_with_re(*values), False) self.assertEqual(get_match_with_string(*values), False)
def test_two_char_middle_position(self): """ test two character in the middle position of string """ values = ('bb', 'abbc') self.assertEqual(get_match_with_iteration(*values), True) self.assertEqual(get_match_with_re(*values), True) self.assertEqual(get_match_with_string(*values), True)
def test_two_char_last_position(self): """ test one character in the last position of string """ values = ('bc', 'abbc') self.assertEqual(get_match_with_iteration(*values), True) self.assertEqual(get_match_with_re(*values), True) self.assertEqual(get_match_with_string(*values), True)
def test_one_char_first_and_last_position(self): """ test one character in the first and last position of string """ values = ('a', 'abca') self.assertEqual(get_match_with_iteration(*values), True) self.assertEqual(get_match_with_re(*values), True) self.assertEqual(get_match_with_string(*values), True)