summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_importlib/test_files.py
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2021-04-05 04:11:23 (GMT)
committerGitHub <noreply@github.com>2021-04-05 04:11:23 (GMT)
commitc8e5eb904e12010d2302364e1037c24a30f5e241 (patch)
treeea1ad39012846500bbb9560262c7f9cd464b62f8 /Lib/test/test_importlib/test_files.py
parentee952b5c7355cb64179ca9bb77b13e7738132d3d (diff)
downloadcpython-c8e5eb904e12010d2302364e1037c24a30f5e241.zip
cpython-c8e5eb904e12010d2302364e1037c24a30f5e241.tar.gz
cpython-c8e5eb904e12010d2302364e1037c24a30f5e241.tar.bz2
bpo-43651: PEP 597: Fix EncodingWarning in some tests (GH-25181)
* Fix test_shutil * Fix test_imp * Fix test_import * Fix test_importlib
Diffstat (limited to 'Lib/test/test_importlib/test_files.py')
-rw-r--r--Lib/test/test_importlib/test_files.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_importlib/test_files.py b/Lib/test/test_importlib/test_files.py
index 1e7a1f3..481829b 100644
--- a/Lib/test/test_importlib/test_files.py
+++ b/Lib/test/test_importlib/test_files.py
@@ -15,7 +15,7 @@ class FilesTests:
def test_read_text(self):
files = resources.files(self.data)
- actual = files.joinpath('utf-8.file').read_text()
+ actual = files.joinpath('utf-8.file').read_text(encoding='utf-8')
assert actual == 'Hello, UTF-8 world!\n'
@unittest.skipUnless(