We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 93db94a commit 72673e0Copy full SHA for 72673e0
Lib/test/test_zipfile/test_core.py
@@ -2685,10 +2685,10 @@ def _test_validate_local_file_entry(self, method):
2685
m_sddnsbd.assert_not_called()
2686
m_sddns.assert_not_called()
2687
2688
- # return None if no sufficient header length
+ # return None if truncated local file header
2689
bytes_ = self._generate_local_file_entry(
2690
'file.txt', b'dummy', compression=method)
2691
- bytes_ = bytes_[:29]
+ bytes_ = bytes_[:zipfile.sizeFileHeader - 1]
2692
fz = io.BytesIO(bytes_)
2693
with mock.patch.object(repacker, '_scan_data_descriptor',
2694
wraps=repacker._scan_data_descriptor) as m_sdd, \
0 commit comments