Skip to content

Commit 1a610d7

Browse files
committed
Fix for ruff check.
1 parent ac070bb commit 1a610d7

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

tests/image/test_webp.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,13 @@ def it_parses_dimensions_from_supported_webp_variants(self, filename, expected_d
4848
assert parser.dimensions == expected_dimensions
4949

5050
@pytest.mark.parametrize(
51-
"blob",
51+
("blob", "match"),
5252
[
53-
b"NOPE" + b"\x00" * 28,
54-
b"RIFF\x00\x00\x00\x00NOPE" + b"\x00" * 16,
55-
b"RIFF\x0e\x00\x00\x00WEBPZZZZ" + b"\x00" * 6,
53+
(b"NOPE" + b"\x00" * 28, "Not a valid WebP file"),
54+
(b"RIFF\x00\x00\x00\x00NOPE" + b"\x00" * 16, "Not a valid WebP file"),
55+
(b"RIFF\x0e\x00\x00\x00WEBPZZZZ" + b"\x00" * 6, "Unsupported WebP format"),
5656
],
5757
)
58-
def it_raises_on_invalid_or_unsupported_webp_streams(self, blob):
59-
with pytest.raises(ValueError):
58+
def it_raises_on_invalid_or_unsupported_webp_streams(self, blob, match):
59+
with pytest.raises(ValueError, match=match):
6060
_WebpParser.parse(io.BytesIO(blob)).dimensions

0 commit comments

Comments
 (0)