summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_asyncio/test_windows_events.py
diff options
context:
space:
mode:
authorYury Selivanov <yselivanov@sprymix.com>2015-05-11 18:48:38 (GMT)
committerYury Selivanov <yselivanov@sprymix.com>2015-05-11 18:48:38 (GMT)
commit59eb9a4da504315345b5b0d8fb8eebddc22ccb92 (patch)
treed86de5b0adb841e211f37adbe00ea8f9b25b343f /Lib/test/test_asyncio/test_windows_events.py
parent740169cd24fc108913e4480e98e608f0517a7b8a (diff)
downloadcpython-59eb9a4da504315345b5b0d8fb8eebddc22ccb92.zip
cpython-59eb9a4da504315345b5b0d8fb8eebddc22ccb92.tar.gz
cpython-59eb9a4da504315345b5b0d8fb8eebddc22ccb92.tar.bz2
asyncio: async() function is deprecated in favour of ensure_future().
Diffstat (limited to 'Lib/test/test_asyncio/test_windows_events.py')
-rw-r--r--Lib/test/test_asyncio/test_windows_events.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_asyncio/test_windows_events.py b/Lib/test/test_asyncio/test_windows_events.py
index 73d8fcd..657a427 100644
--- a/Lib/test/test_asyncio/test_windows_events.py
+++ b/Lib/test/test_asyncio/test_windows_events.py
@@ -37,7 +37,7 @@ class ProactorTests(test_utils.TestCase):
def test_close(self):
a, b = self.loop._socketpair()
trans = self.loop._make_socket_transport(a, asyncio.Protocol())
- f = asyncio.async(self.loop.sock_recv(b, 100))
+ f = asyncio.ensure_future(self.loop.sock_recv(b, 100))
trans.close()
self.loop.run_until_complete(f)
self.assertEqual(f.result(), b'')