diff --git a/Lib/test/test_wave.py b/Lib/test/test_wave.py index d3723c04820d9d..2f7e4e36109c54 100644 --- a/Lib/test/test_wave.py +++ b/Lib/test/test_wave.py @@ -333,6 +333,13 @@ def test_read_wrong_sample_width(self): with self.assertRaisesRegex(wave.Error, 'bad sample width'): wave.open(io.BytesIO(b)) + def test_read_truncated_fmt_chunk(self): + b = b'RIFF' + struct.pack('