mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
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
1 changed files with 1 additions and 1 deletions
|
@ -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…
Add table
Add a link
Reference in a new issue