mirror of
https://github.com/python/cpython.git
synced 2025-12-10 02:50:09 +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
|
|
@ -12,7 +12,9 @@ class CFunctionCalls(unittest.TestCase):
|
|||
self.assertRaises(TypeError, {}.has_key)
|
||||
|
||||
def test_varargs1(self):
|
||||
{}.has_key(0)
|
||||
# Silence Py3k warning
|
||||
with test_support.check_warnings():
|
||||
{}.has_key(0)
|
||||
|
||||
def test_varargs2(self):
|
||||
self.assertRaises(TypeError, {}.has_key, 0, 1)
|
||||
|
|
@ -24,11 +26,15 @@ class CFunctionCalls(unittest.TestCase):
|
|||
pass
|
||||
|
||||
def test_varargs1_ext(self):
|
||||
{}.has_key(*(0,))
|
||||
# Silence Py3k warning
|
||||
with test_support.check_warnings():
|
||||
{}.has_key(*(0,))
|
||||
|
||||
def test_varargs2_ext(self):
|
||||
try:
|
||||
{}.has_key(*(1, 2))
|
||||
# Silence Py3k warning
|
||||
with test_support.check_warnings():
|
||||
{}.has_key(*(1, 2))
|
||||
except TypeError:
|
||||
pass
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue