MCPcopy
hub / github.com/pex-tool/pex / Tempdir

Class Tempdir

testing/pytest_utils/tmp.py:43–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

41
42@attr.s(frozen=True)
43class Tempdir(object):
44 path = attr.ib(converter=_realpath) # type: str
45 symlink = attr.ib(default=None) # type: Optional[str]
46
47 def join(self, *components):
48 # type: (*str) -> str
49 return os.path.join(self.path, *components)
50
51 def safe_remove(self):
52 # type: () -> None
53 if self.symlink:
54 safe_delete(self.symlink)
55 safe_rmtree(self.path)
56
57 def __str__(self):
58 # type: () -> str
59 return self.path
60
61
62@attr.s(frozen=True)

Callers 1

mktempMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected