Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 689267a commit 1ae16eaCopy full SHA for 1ae16ea
2 files changed
Lib/test/test_types.py
@@ -1383,7 +1383,7 @@ class G(typing.NamedTuple):
1383
1384
self.assertIs(types.get_original_bases(G)[0], typing.NamedTuple)
1385
1386
- with self.assertRaises(TypeError):
+ with self.assertRaisesRegex(TypeError, "Expected an instance of type"):
1387
types.get_original_bases(object())
1388
1389
# Many of the following tests are derived from test_descr.py
Lib/types.py
@@ -147,8 +147,6 @@ def _calculate_meta(meta, bases):
147
def get_original_bases(cls, /):
148
"""Return the class's "original" bases prior to modification by `__mro_entries__`.
149
150
- This is useful for introspecting Generics.
151
-
152
Examples::
153
154
from typing import TypeVar, Generic
0 commit comments