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

Method temp_dir

Lib/test/test_interpreters/utils.py:399–404  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

397 return r, w
398
399 def temp_dir(self):
400 tempdir = tempfile.mkdtemp()
401 tempdir = os.path.realpath(tempdir)
402 from test.support import os_helper
403 self.addCleanup(lambda: os_helper.rmtree(tempdir))
404 return tempdir
405
406 @contextlib.contextmanager
407 def captured_thread_exception(self):

Calls 3

mkdtempMethod · 0.80
addCleanupMethod · 0.80
realpathMethod · 0.45