MCPcopy
hub / github.com/python-trio/trio / socket

Method socket

src/trio/_tests/test_socket.py:1133–1139  ·  view source on GitHub ↗
(
            self,
            family: AddressFamily,
            type: SocketKind,
            proto: int,
        )

Source from the content-addressed store, hash-verified

1131async def test_custom_socket_factory() -> None:
1132 class CustomSocketFactory:
1133 def socket(
1134 self,
1135 family: AddressFamily,
1136 type: SocketKind,
1137 proto: int,
1138 ) -> tuple[str, AddressFamily, SocketKind, int]:
1139 return ("hi", family, type, proto)
1140
1141 csf = CustomSocketFactory()
1142

Callers 15

__init__Method · 0.45
tutil.pyFile · 0.45
test_basic_udpFunction · 0.45
test_msg_truncFunction · 0.45
test_recv_methodsFunction · 0.45
test_basic_tcpFunction · 0.45
test_getpeernameFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected