mirror of
https://github.com/python/cpython.git
synced 2025-11-18 18:31:56 +00:00
Cleaned up test (removing bogus argument list).
This commit is contained in:
parent
e03e5b1f91
commit
babc83a27a
1 changed files with 2 additions and 2 deletions
|
|
@ -564,8 +564,8 @@ if type(dictlike().fromkeys('a')) is not dictlike:
|
||||||
raise TestFailed, 'dictsubclass.fromkeys created wrong type'
|
raise TestFailed, 'dictsubclass.fromkeys created wrong type'
|
||||||
from UserDict import UserDict
|
from UserDict import UserDict
|
||||||
class mydict(dict):
|
class mydict(dict):
|
||||||
def __new__(cls, *args, **kwargs):
|
def __new__(cls):
|
||||||
return UserDict(*args, **kwargs)
|
return UserDict()
|
||||||
ud = mydict.fromkeys('ab')
|
ud = mydict.fromkeys('ab')
|
||||||
if ud != {'a':None, 'b':None} or not isinstance(ud,UserDict):
|
if ud != {'a':None, 'b':None} or not isinstance(ud,UserDict):
|
||||||
raise TestFailed, 'fromkeys did not instantiate using __new__'
|
raise TestFailed, 'fromkeys did not instantiate using __new__'
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue