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

Method test_audit_run_startup

Lib/test/test_embed.py:1970–1980  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1968 os.unlink(startup)
1969
1970 def test_audit_run_startup(self):
1971 startup = os.path.join(self.oldcwd, os_helper.TESTFN) + ".py"
1972 with open(startup, "w", encoding="utf-8") as f:
1973 print("pass", file=f)
1974 try:
1975 env = {**remove_python_envvars(), "PYTHONSTARTUP": startup}
1976 self.run_embedded_interpreter("test_audit_run_startup",
1977 timeout=support.SHORT_TIMEOUT,
1978 returncode=10, env=env)
1979 finally:
1980 os.unlink(startup)
1981
1982 def test_audit_run_stdin(self):
1983 self.run_embedded_interpreter("test_audit_run_stdin",

Callers

nothing calls this directly

Calls 5

remove_python_envvarsFunction · 0.85
openFunction · 0.50
joinMethod · 0.45
unlinkMethod · 0.45

Tested by

no test coverage detected