Skip to content

Commit

Permalink
bpo-30445: Allow appended output in RecursionError message
Browse files Browse the repository at this point in the history
Running under coverage sometimes causes 'in comparison' to be added to the end of the RecursionError message, which is acceptable.

Patched by Maria Mckinley
  • Loading branch information
codedragon authored and zware committed May 24, 2017
1 parent 7c2f82d commit 3480ef9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Lib/test/test_traceback.py
Expand Up @@ -344,7 +344,8 @@ def f():
# 2nd last line contains the repetition count
self.assertEqual(actual[:-2], expected[:-2])
self.assertRegex(actual[-2], expected[-2])
self.assertEqual(actual[-1], expected[-1])
# last line can have additional text appended
self.assertIn(expected[-1], actual[-1])

# Check the recursion count is roughly as expected
rec_limit = sys.getrecursionlimit()
Expand Down

0 comments on commit 3480ef9

Please sign in to comment.