mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-06-29 17:33:08 +03:00
test_image_draft: skip if no JPEG support.
This commit is contained in:
parent
e2221de8f5
commit
a5a5c854b8
|
@ -2,6 +2,11 @@ from tester import *
|
||||||
|
|
||||||
from PIL import Image
|
from PIL import Image
|
||||||
|
|
||||||
|
codecs = dir(Image.core)
|
||||||
|
|
||||||
|
if "jpeg_encoder" not in codecs or "jpeg_decoder" not in codecs:
|
||||||
|
skip("jpeg support not available")
|
||||||
|
|
||||||
filename = "Images/lena.jpg"
|
filename = "Images/lena.jpg"
|
||||||
|
|
||||||
data = tostring(Image.open(filename).resize((512, 512)), "JPEG")
|
data = tostring(Image.open(filename).resize((512, 512)), "JPEG")
|
||||||
|
|
Loading…
Reference in New Issue
Block a user