summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_metaclass.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_metaclass.py')
-rw-r--r--Lib/test/test_metaclass.py11
1 files changed, 3 insertions, 8 deletions
diff --git a/Lib/test/test_metaclass.py b/Lib/test/test_metaclass.py
index 4db792e..e6fe20a 100644
--- a/Lib/test/test_metaclass.py
+++ b/Lib/test/test_metaclass.py
@@ -180,7 +180,7 @@ Use a metaclass that doesn't derive from type.
meta: C ()
ns: [('__module__', 'test.test_metaclass'), ('__qualname__', 'C'), ('a', 42), ('b', 24)]
kw: []
- >>> type(C) is types._DefaultClassNamespaceType
+ >>> type(C) is dict
True
>>> print(sorted(C.items()))
[('__module__', 'test.test_metaclass'), ('__qualname__', 'C'), ('a', 42), ('b', 24)]
@@ -211,11 +211,8 @@ And again, with a __prepare__ attribute.
The default metaclass must define a __prepare__() method.
- >>> ns = type.__prepare__()
- >>> type(ns) is types._DefaultClassNamespaceType
- True
- >>> list(ns) == []
- True
+ >>> type.__prepare__()
+ {}
>>>
Make sure it works with subclassing.
@@ -251,9 +248,7 @@ Test failures in looking up the __prepare__ method work.
"""
-from collections import OrderedDict
import sys
-import types
# Trace function introduces __locals__ which causes various tests to fail.
if hasattr(sys, 'gettrace') and sys.gettrace():