mirror of
https://github.com/python/cpython.git
synced 2025-11-01 18:51:43 +00:00
Fixing - Issue7026 - RuntimeError: dictionary changed size during iteration. Patch by flox
This commit is contained in:
parent
3194d1454c
commit
3ddc435af6
107 changed files with 794 additions and 436 deletions
|
|
@ -356,7 +356,8 @@ class TestErrorHandling(unittest.TestCase):
|
|||
for f in (self.module.nlargest, self.module.nsmallest):
|
||||
for s in ("123", "", range(1000), ('do', 1.2), xrange(2000,2200,5)):
|
||||
for g in (G, I, Ig, L, R):
|
||||
self.assertEqual(f(2, g(s)), f(2,s))
|
||||
with test_support.check_warnings():
|
||||
self.assertEqual(f(2, g(s)), f(2,s))
|
||||
self.assertEqual(f(2, S(s)), [])
|
||||
self.assertRaises(TypeError, f, 2, X(s))
|
||||
self.assertRaises(TypeError, f, 2, N(s))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue