summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Lib/test/test_zipfile.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/Lib/test/test_zipfile.py b/Lib/test/test_zipfile.py
index c69892b..6878262 100644
--- a/Lib/test/test_zipfile.py
+++ b/Lib/test/test_zipfile.py
@@ -544,10 +544,12 @@ class OtherTests(unittest.TestCase):
def testUnicodeFilenames(self):
zf = zipfile.ZipFile(TESTFN, "w")
zf.writestr("foo.txt", "Test for unicode filename")
- zf.writestr("fo\xf6.txt", "Test for unicode filename")
+ zf.writestr("\xf6.txt", "Test for unicode filename")
+ zf.close()
+ zf = zipfile.ZipFile(TESTFN, "r")
+ self.assertEqual(zf.filelist[0].filename, "foo.txt")
+ self.assertEqual(zf.filelist[1].filename, "\xf6.txt")
zf.close()
- zf = zipfile.ZipFile(TESTFN, "w")
-
def testCreateNonExistentFileForAppend(self):
if os.path.exists(TESTFN):