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

Method test_recursion_limit

Lib/test/test_difflib.py:257–262  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

255 self.assertEqual(actual, fp.read())
256
257 def test_recursion_limit(self):
258 # Check if the problem described in patch #1413711 exists.
259 limit = sys.getrecursionlimit()
260 old = [(i%2 and "K:%d" or "V:A:%d") % i for i in range(limit*2)]
261 new = [(i%2 and "K:%d" or "V:B:%d") % i for i in range(limit*2)]
262 difflib.SequenceMatcher(None, old, new).get_opcodes()
263
264 def test_make_file_default_charset(self):
265 html_diff = difflib.HtmlDiff()

Callers

nothing calls this directly

Calls 1

get_opcodesMethod · 0.80

Tested by

no test coverage detected