Skip to content

Commit 1598dac

Browse files
committed
Mock to ensure sanitization works across OS
1 parent 5f5da15 commit 1598dac

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

Lib/test/test_zipfile/test_core.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4827,6 +4827,8 @@ def test_overlap_with_archive_comment(self):
48274827
with self.assertRaisesRegex(zipfile.BadZipFile, 'Overlapped entries'):
48284828
zipf.read('a')
48294829

4830+
@mock.patch('os.sep', '\\')
4831+
@mock.patch('os.altsep', '/')
48304832
def test_append_keep_filename(self):
48314833
"""Files loaded from an archive should keep original filename when
48324834
rewritten to central directory in append mode."""

0 commit comments

Comments
 (0)