summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_asyncio
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2014-02-20 16:01:11 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2014-02-20 16:01:11 (GMT)
commit0211ed3e8988417624db1c51baa23c666babcbdc (patch)
treec7edde2324d5eda746fd6adf53abd4abc4ee4316 /Lib/test/test_asyncio
parent013dece44daf2483c2ba2771d7d01de28f33ab50 (diff)
downloadcpython-0211ed3e8988417624db1c51baa23c666babcbdc.zip
cpython-0211ed3e8988417624db1c51baa23c666babcbdc.tar.gz
cpython-0211ed3e8988417624db1c51baa23c666babcbdc.tar.bz2
asyncio: ops, and now fix also the unit test for IPv6 address:
test_sock_connect_address()
Diffstat (limited to 'Lib/test/test_asyncio')
-rw-r--r--Lib/test/test_asyncio/test_events.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/Lib/test/test_asyncio/test_events.py b/Lib/test/test_asyncio/test_events.py
index 3720cc7..f8499dc 100644
--- a/Lib/test/test_asyncio/test_events.py
+++ b/Lib/test/test_asyncio/test_events.py
@@ -1335,12 +1335,11 @@ class EventLoopTestsMixin:
'selector': self.loop._selector.__class__.__name__})
def test_sock_connect_address(self):
- families = [socket.AF_INET]
+ families = [(socket.AF_INET, ('www.python.org', 80))]
if support.IPV6_ENABLED:
- families.append(socket.AF_INET6)
+ families.append((socket.AF_INET6, ('www.python.org', 80, 0, 0)))
- address = ('www.python.org', 80)
- for family in families:
+ for family, address in families:
for sock_type in (socket.SOCK_STREAM, socket.SOCK_DGRAM):
sock = socket.socket(family, sock_type)
with sock: