MCPcopy Index your code
hub / github.com/python/cpython / _testWithTimeoutTriggeredSend

Method _testWithTimeoutTriggeredSend

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

Source from the content-addressed store, hash-verified

7030 # timeout (triggered)
7031
7032 def _testWithTimeoutTriggeredSend(self):
7033 address = self.serv.getsockname()
7034 with open(os_helper.TESTFN, 'rb') as file:
7035 with socket.create_connection(address) as sock:
7036 sock.settimeout(0.01)
7037 meth = self.meth_from_sock(sock)
7038 self.assertRaises(TimeoutError, meth, file)
7039
7040 def testWithTimeoutTriggeredSend(self):
7041 conn = self.accept_conn()

Callers

nothing calls this directly

Calls 6

meth_from_sockMethod · 0.95
openFunction · 0.50
getsocknameMethod · 0.45
create_connectionMethod · 0.45
settimeoutMethod · 0.45
assertRaisesMethod · 0.45

Tested by

no test coverage detected