diff --git a/Tests/test_file_png.py b/Tests/test_file_png.py index 5eca75deb..345abf11b 100644 --- a/Tests/test_file_png.py +++ b/Tests/test_file_png.py @@ -592,14 +592,17 @@ class TestFilePng: with Image.open("Tests/images/hopper_idat_after_image_end.png") as im: assert im.text == {"TXT": "VALUE", "ZIP": "VALUE"} - def test_exif(self): - for test_file in ( + @pytest.mark.parametrize( + "test_file", + [ "Tests/images/exif.png", # With an EXIF chunk "Tests/images/exif_imagemagick.png", # With an ImageMagick zTXt chunk - ): - with Image.open(test_file) as im: - exif = im._getexif() - assert exif[274] == 1 + ], + ) + def test_exif(self, test_file): + with Image.open(test_file) as im: + exif = im._getexif() + assert exif[274] == 1 def test_exif_save(self, tmp_path): with Image.open("Tests/images/exif.png") as im: