mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-07-06 12:53:12 +03:00
Test ImageCms.profileToProfile with invalid flags
This commit is contained in:
parent
b47bcc246f
commit
6c889d1088
|
@ -210,6 +210,15 @@ def test_invalid_color_temperature():
|
||||||
ImageCms.createProfile("LAB", "invalid")
|
ImageCms.createProfile("LAB", "invalid")
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.parametrize("flag", ("my string", -1))
|
||||||
|
def test_invalid_flag(flag):
|
||||||
|
with hopper() as im:
|
||||||
|
with pytest.raises(
|
||||||
|
ImageCms.PyCMSError, match="flags must be an integer between 0 and "
|
||||||
|
):
|
||||||
|
ImageCms.profileToProfile(im, "foo", "bar", flags=flag)
|
||||||
|
|
||||||
|
|
||||||
def test_simple_lab():
|
def test_simple_lab():
|
||||||
i = Image.new("RGB", (10, 10), (128, 128, 128))
|
i = Image.new("RGB", (10, 10), (128, 128, 128))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user