bpo-41401: Fix test_fspath_support in test_io. (GH-21640)
The error is exposed on non-UTF-8 locales.
This commit is contained in:
parent
855e68855e
commit
67987acd5d
|
@ -928,7 +928,7 @@ class IOTest(unittest.TestCase):
|
|||
self.assertEqual(f.read(), "egg\n")
|
||||
|
||||
check_path_succeeds(FakePath(os_helper.TESTFN))
|
||||
check_path_succeeds(FakePath(os_helper.TESTFN.encode('utf-8')))
|
||||
check_path_succeeds(FakePath(os.fsencode(os_helper.TESTFN)))
|
||||
|
||||
with self.open(os_helper.TESTFN, "w") as f:
|
||||
bad_path = FakePath(f.fileno())
|
||||
|
|
Loading…
Reference in New Issue