diff options
Diffstat (limited to 'Lib/test/test_os.py')
-rw-r--r-- | Lib/test/test_os.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_os.py b/Lib/test/test_os.py index 014d874f4d..c680d8d77a 100644 --- a/Lib/test/test_os.py +++ b/Lib/test/test_os.py @@ -708,13 +708,13 @@ if sys.platform != 'win32': self.fsencoding = sys.getfilesystemencoding() sys.setfilesystemencoding("utf-8") self.dir = support.TESTFN - self.bdir = self.dir.encode("utf-8", "utf8b") + self.bdir = self.dir.encode("utf-8", "surrogateescape") os.mkdir(self.dir) self.unicodefn = [] for fn in self.filenames: f = open(os.path.join(self.bdir, fn), "w") f.close() - self.unicodefn.append(fn.decode("utf-8", "utf8b")) + self.unicodefn.append(fn.decode("utf-8", "surrogateescape")) def tearDown(self): shutil.rmtree(self.dir) |