mirror of
https://github.com/python/cpython.git
synced 2025-08-30 21:48:47 +00:00
bpo-41069: Make TESTFN and the CWD for tests containing non-ascii characters. (GH-21035)
This commit is contained in:
parent
8ea6353f60
commit
700cfa8c90
24 changed files with 110 additions and 77 deletions
|
@ -1349,7 +1349,7 @@ class AuditingTests(EmbeddingTestsMixin, unittest.TestCase):
|
|||
returncode=1)
|
||||
|
||||
def test_audit_run_interactivehook(self):
|
||||
startup = os.path.join(self.oldcwd, support.TESTFN) + (support.FS_NONASCII or '') + ".py"
|
||||
startup = os.path.join(self.oldcwd, support.TESTFN) + ".py"
|
||||
with open(startup, "w", encoding="utf-8") as f:
|
||||
print("import sys", file=f)
|
||||
print("sys.__interactivehook__ = lambda: None", file=f)
|
||||
|
@ -1362,7 +1362,7 @@ class AuditingTests(EmbeddingTestsMixin, unittest.TestCase):
|
|||
os.unlink(startup)
|
||||
|
||||
def test_audit_run_startup(self):
|
||||
startup = os.path.join(self.oldcwd, support.TESTFN) + (support.FS_NONASCII or '') + ".py"
|
||||
startup = os.path.join(self.oldcwd, support.TESTFN) + ".py"
|
||||
with open(startup, "w", encoding="utf-8") as f:
|
||||
print("pass", file=f)
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue