diff options
author | Lars Gustäbel <lars@gustaebel.de> | 2016-04-19 09:59:39 (GMT) |
---|---|---|
committer | Lars Gustäbel <lars@gustaebel.de> | 2016-04-19 09:59:39 (GMT) |
commit | daac5f9f92edc279ecbc2450be4cbca11337584d (patch) | |
tree | 67004bc7a4a0e6d676545328a27f889480c7fd77 /Lib | |
parent | 7c3e6848f200360ce4a7de514801d0d3b7a9da3f (diff) | |
parent | ddd9917ac3f45a1bab9a200a6fe60a3407d1780d (diff) | |
download | cpython-daac5f9f92edc279ecbc2450be4cbca11337584d.zip cpython-daac5f9f92edc279ecbc2450be4cbca11337584d.tar.gz cpython-daac5f9f92edc279ecbc2450be4cbca11337584d.tar.bz2 |
Issue #24838: Merge test_tarfile.py fix from 3.5.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_tarfile.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/test_tarfile.py b/Lib/test/test_tarfile.py index b3d0d4e..d7785ce 100644 --- a/Lib/test/test_tarfile.py +++ b/Lib/test/test_tarfile.py @@ -1795,7 +1795,7 @@ class UstarUnicodeTest(UnicodeTest, unittest.TestCase): self.assertRaises(exc, tar.addfile, t) if exc is None: - with tarfile.open(tmpname, "r") as tar: + with tarfile.open(tmpname, "r", encoding="utf-8") as tar: for t in tar: self.assertEqual(name, t.name) break @@ -1821,7 +1821,7 @@ class UstarUnicodeTest(UnicodeTest, unittest.TestCase): self.assertRaises(exc, tar.addfile, t) if exc is None: - with tarfile.open(tmpname, "r") as tar: + with tarfile.open(tmpname, "r", encoding="utf-8") as tar: for t in tar: self.assertEqual(name, t.linkname) break |