MCPcopy Index your code
hub / github.com/RustPython/RustPython / testAutoBindSock

Method testAutoBindSock

Lib/test/test_socket.py:2573–2576  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2571 self.assertRaises(OSError, socket_helper.bind_port, s, host=-2)
2572
2573 def testAutoBindSock(self):
2574 with socket.socket(socket.AF_QIPCRTR, socket.SOCK_DGRAM) as s:
2575 s.connect((123, 123))
2576 self.assertNotEqual(s.getsockname()[1], 0)
2577
2578@unittest.skipIf(fcntl is None, "need fcntl")
2579@unittest.skipUnless(HAVE_SOCKET_VSOCK,

Callers

nothing calls this directly

Calls 4

socketMethod · 0.80
assertNotEqualMethod · 0.80
connectMethod · 0.45
getsocknameMethod · 0.45

Tested by

no test coverage detected