summaryrefslogtreecommitdiff
path: root/Lib/test/test_asyncio/test_futures.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_asyncio/test_futures.py')
-rw-r--r--Lib/test/test_asyncio/test_futures.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/test/test_asyncio/test_futures.py b/Lib/test/test_asyncio/test_futures.py
index c16bfc08a7..939ad7be6a 100644
--- a/Lib/test/test_asyncio/test_futures.py
+++ b/Lib/test/test_asyncio/test_futures.py
@@ -7,7 +7,7 @@ import sys
import threading
import unittest
from unittest import mock
-
+from types import GenericAlias
import asyncio
from asyncio import futures
from test.test_asyncio import utils as test_utils
@@ -109,6 +109,11 @@ class BaseFutureTests:
self.loop = self.new_test_loop()
self.addCleanup(self.loop.close)
+ def test_generic_alias(self):
+ future = self.cls[str]
+ self.assertEqual(future.__args__, (str,))
+ self.assertIsInstance(future, GenericAlias)
+
def test_isfuture(self):
class MyFuture:
_asyncio_future_blocking = None