mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-23 05:34:45 +03:00
non-animated png sanity tests
This commit is contained in:
parent
dc56c6064f
commit
2e6adc5793
|
@ -85,6 +85,8 @@ class TestFilePng:
|
||||||
assert im.size == (128, 128)
|
assert im.size == (128, 128)
|
||||||
assert im.format == "PNG"
|
assert im.format == "PNG"
|
||||||
assert im.get_format_mimetype() == "image/png"
|
assert im.get_format_mimetype() == "image/png"
|
||||||
|
assert im.n_frames == 1
|
||||||
|
assert not im.is_animated
|
||||||
|
|
||||||
for mode in ["1", "L", "P", "RGB", "I", "I;16"]:
|
for mode in ["1", "L", "P", "RGB", "I", "I;16"]:
|
||||||
im = hopper(mode)
|
im = hopper(mode)
|
||||||
|
@ -635,7 +637,6 @@ class TestFilePng:
|
||||||
|
|
||||||
def test_seek(self):
|
def test_seek(self):
|
||||||
with Image.open(TEST_PNG_FILE) as im:
|
with Image.open(TEST_PNG_FILE) as im:
|
||||||
assert im.n_frames == 1
|
|
||||||
im.seek(0)
|
im.seek(0)
|
||||||
with pytest.raises(EOFError):
|
with pytest.raises(EOFError):
|
||||||
im.seek(1)
|
im.seek(1)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user