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

Method createAndSendFDs

Lib/test/test_socket.py:4076–4084  ·  view source on GitHub ↗
(self, n)

Source from the content-addressed store, hash-verified

4074 os.close(fd)
4075
4076 def createAndSendFDs(self, n):
4077 # Send n new file descriptors created by newFDs() to the
4078 # server, with the constant MSG as the non-ancillary data.
4079 self.assertEqual(
4080 self.sendmsgToServer([MSG],
4081 [(socket.SOL_SOCKET,
4082 socket.SCM_RIGHTS,
4083 array.array("i", self.newFDs(n)))]),
4084 len(MSG))
4085
4086 def checkRecvmsgFDs(self, numfds, result, maxcmsgs=1, ignoreflags=0):
4087 # Check that constant MSG was received with numfds file

Callers 12

_testMultipleFDPassMethod · 0.95
_testFDPassCMSG_SPACEMethod · 0.95
_testFDPassCMSG_LENMethod · 0.95
_testCmsgTrunc0Method · 0.95
_testCmsgTrunc1Method · 0.95
_testCmsgTrunc2IntMethod · 0.95
_testCmsgTruncLen0Method · 0.95
_testCmsgTruncLen1Method · 0.95

Calls 3

newFDsMethod · 0.95
sendmsgToServerMethod · 0.80
assertEqualMethod · 0.45

Tested by

no test coverage detected