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

Method setUp

Lib/test/test_remote_pdb.py:1492–1498  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1490@requires_subprocess()
1491class PdbAttachTestCase(unittest.TestCase):
1492 def setUp(self):
1493 # Create a server socket that will wait for the debugger to connect
1494 self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
1495 self.sock.bind(('127.0.0.1', 0)) # Let OS assign port
1496 self.sock.listen(1)
1497 self.port = self.sock.getsockname()[1]
1498 self._create_script()
1499
1500 def _create_script(self, script=None):
1501 # Create a file for subprocess script

Callers

nothing calls this directly

Calls 5

_create_scriptMethod · 0.95
socketMethod · 0.80
bindMethod · 0.45
listenMethod · 0.45
getsocknameMethod · 0.45

Tested by

no test coverage detected