# Shouldn't crash; see https://github.com/python/typing/issues/259
typing.List[Callable[..., str]]
+ def test_or_and_ror(self):
+ Callable = self.Callable
+ self.assertEqual(Callable | Tuple, Union[Callable, Tuple])
+ self.assertEqual(Tuple | Callable, Union[Tuple, Callable])
def test_basic(self):
Callable = self.Callable
A.register(B)
self.assertIsSubclass(B, typing.Mapping)
+ def test_or_and_ror(self):
+ self.assertEqual(typing.Sized | typing.Awaitable, Union[typing.Sized, typing.Awaitable])
+ self.assertEqual(typing.Coroutine | typing.Hashable, Union[typing.Coroutine, typing.Hashable])
+
class OtherABCTests(BaseTestCase):