Skip to content

Commit 297e1c3

Browse files
methanejaraco
authored andcommitted
bpo-43651: PEP 597: Fix EncodingWarning in some tests (GH-25181)
* Fix test_shutil * Fix test_imp * Fix test_import * Fix test_importlib
1 parent a8c2ead commit 297e1c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

importlib_resources/tests/test_files.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ def test_read_bytes(self):
1515

1616
def test_read_text(self):
1717
files = resources.files(self.data)
18-
actual = files.joinpath('utf-8.file').read_text()
18+
actual = files.joinpath('utf-8.file').read_text(encoding='utf-8')
1919
assert actual == 'Hello, UTF-8 world!\n'
2020

2121
@unittest.skipUnless(

0 commit comments

Comments
 (0)