diff options
| author | Martin v. Löwis <martin@v.loewis.de> | 2009-05-24 19:42:14 (GMT) |
|---|---|---|
| committer | Martin v. Löwis <martin@v.loewis.de> | 2009-05-24 19:42:14 (GMT) |
| commit | e7e46f8152b50f76114b324171d69f88512e98cb (patch) | |
| tree | 4a66115e8b421548954f3e37cd02c956200330cf /Lib/test/test_zipfile.py | |
| parent | 6c3064beed67b4cd5dc23264ed9520eaeec4cb6d (diff) | |
| download | cpython-e7e46f8152b50f76114b324171d69f88512e98cb.zip cpython-e7e46f8152b50f76114b324171d69f88512e98cb.tar.gz cpython-e7e46f8152b50f76114b324171d69f88512e98cb.tar.bz2 | |
Merged revisions 72893 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r72893 | martin.v.loewis | 2009-05-24 21:30:52 +0200 (So, 24 Mai 2009) | 3 lines
Issue #6050: Don't fail extracting a directory from a zipfile if
the directory already exists.
........
Diffstat (limited to 'Lib/test/test_zipfile.py')
| -rw-r--r-- | Lib/test/test_zipfile.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_zipfile.py b/Lib/test/test_zipfile.py index 21fc703..1fed79a 100644 --- a/Lib/test/test_zipfile.py +++ b/Lib/test/test_zipfile.py @@ -994,6 +994,11 @@ class TestWithDirectory(unittest.TestCase): self.assertTrue(os.path.isdir(os.path.join(TESTFN2, "a", "b"))) self.assertTrue(os.path.exists(os.path.join(TESTFN2, "a", "b", "c"))) + def test_bug_6050(self): + # Extraction should succeed if directories already exist + os.mkdir(os.path.join(TESTFN2, "a")) + self.testExtractDir() + def testStoreDir(self): os.mkdir(os.path.join(TESTFN2, "x")) zipf = zipfile.ZipFile(TESTFN, "w") |
