MCPcopy Index your code
hub / github.com/python-pillow/Pillow / test_incremental_webp

Method test_incremental_webp

Tests/test_imagefile.py:107–117  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

105
106 @skip_unless_feature("webp")
107 def test_incremental_webp(self) -> None:
108 with ImageFile.Parser() as p:
109 with open("Tests/images/hopper.webp", "rb") as f:
110 p.feed(f.read(1024))
111
112 # Check that insufficient data was given in the first feed
113 assert not p.image
114
115 p.feed(f.read())
116 assert p.image is not None
117 assert (128, 128) == p.image.size
118
119 @skip_unless_feature("zlib")
120 def test_safeblock(self, monkeypatch: pytest.MonkeyPatch) -> None:

Callers

nothing calls this directly

Calls 3

feedMethod · 0.80
openFunction · 0.50
readMethod · 0.45

Tested by

no test coverage detected