From f64abb34037e81276c573de36b0b409514756c39 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 26 May 2023 07:54:54 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- Tests/test_file_png.py | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/Tests/test_file_png.py b/Tests/test_file_png.py index 5bfbbbab8..a3669ef5a 100644 --- a/Tests/test_file_png.py +++ b/Tests/test_file_png.py @@ -99,18 +99,27 @@ class TestFilePng: if mode == "I;16": reloaded = reloaded.convert(mode) assert_image_equal(reloaded, im) - + def test_putpalette(self): valid_file = "Tests/images/FudanPed00003_mask.png" with pytest.raises(ValueError) as err: mask = Image.open(valid_file) - mask.putpalette([ - 0, 0, 0, # black background - 255, 0, 0, # index 1 is red - 255, 255, 0, # index 2 is yellow - 255, 153, 0, # index 3 is orange - ]) - + mask.putpalette( + [ + 0, + 0, + 0, # black background + 255, + 0, + 0, # index 1 is red + 255, + 255, + 0, # index 2 is yellow + 255, + 153, + 0, # index 3 is orange + ] + ) def test_invalid_file(self): invalid_file = "Tests/images/flower.jpg"