(self)
| 1955 | returncode=1) |
| 1956 | |
| 1957 | def test_audit_run_interactivehook(self): |
| 1958 | startup = os.path.join(self.oldcwd, os_helper.TESTFN) + ".py" |
| 1959 | with open(startup, "w", encoding="utf-8") as f: |
| 1960 | print("import sys", file=f) |
| 1961 | print("sys.__interactivehook__ = lambda: None", file=f) |
| 1962 | try: |
| 1963 | env = {**remove_python_envvars(), "PYTHONSTARTUP": startup} |
| 1964 | self.run_embedded_interpreter("test_audit_run_interactivehook", |
| 1965 | timeout=support.SHORT_TIMEOUT, |
| 1966 | returncode=10, env=env) |
| 1967 | finally: |
| 1968 | os.unlink(startup) |
| 1969 | |
| 1970 | def test_audit_run_startup(self): |
| 1971 | startup = os.path.join(self.oldcwd, os_helper.TESTFN) + ".py" |
nothing calls this directly
no test coverage detected