Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions trio/tests/test_socket.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
import socket as stdlib_socket
import inspect

from .._core.tests.tutil import slow

from .. import _core
from .. import socket as tsocket
from ..testing import assert_yields, wait_all_tasks_blocked
Expand Down Expand Up @@ -549,6 +551,8 @@ def connect(self, *args, **kwargs):
await sock.connect(listener.getsockname())
assert sock.fileno() == -1

@slow
async def test_SocketType_connect_paths_not_listening():
# Failed connect (hopefully after raising BlockingIOError)
with tsocket.socket() as sock, tsocket.socket() as non_listener:
# Claim an unused port
Expand Down