MCPcopy Index your code
hub / github.com/python/cpython / test_MARK_PUSH_macro_bug

Method test_MARK_PUSH_macro_bug

Lib/test/test_re.py:2429–2435  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2427 {'tag': 'foo', 'text': None}])
2428
2429 def test_MARK_PUSH_macro_bug(self):
2430 # issue35859, MARK_PUSH() macro didn't protect MARK-0 if it
2431 # was the only available mark.
2432 self.assertEqual(re.match(r'(ab|a)*?b', 'ab').groups(), ('a',))
2433 self.assertEqual(re.match(r'(ab|a)+?b', 'ab').groups(), ('a',))
2434 self.assertEqual(re.match(r'(ab|a){0,2}?b', 'ab').groups(), ('a',))
2435 self.assertEqual(re.match(r'(.b|a)*?b', 'ab').groups(), ('a',))
2436
2437 def test_MIN_UNTIL_mark_bug(self):
2438 # Fixed in issue35859, reported in issue9134.

Callers

nothing calls this directly

Calls 3

assertEqualMethod · 0.45
groupsMethod · 0.45
matchMethod · 0.45

Tested by

no test coverage detected