mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-02-03 21:24:31 +03:00
Skip libimagequant's test if it's unavailable
This commit is contained in:
parent
8b7fb44c6b
commit
c5278000c5
|
@ -18,7 +18,13 @@ class TestImageQuantize(PillowTestCase):
|
||||||
def test_libimagequant_quantize(self):
|
def test_libimagequant_quantize(self):
|
||||||
im = hopper()
|
im = hopper()
|
||||||
|
|
||||||
im = im.quantize(100, Image.LIBIMAGEQUANT)
|
try:
|
||||||
|
im = im.quantize(100, Image.LIBIMAGEQUANT)
|
||||||
|
except ValueError as ex:
|
||||||
|
if 'dependency' in str(ex).lower():
|
||||||
|
self.skipTest('libimagepng support not available')
|
||||||
|
else:
|
||||||
|
raise
|
||||||
self.assert_image(im, "P", im.size)
|
self.assert_image(im, "P", im.size)
|
||||||
|
|
||||||
assert len(im.getcolors()) == 100
|
assert len(im.getcolors()) == 100
|
||||||
|
|
|
@ -15,4 +15,4 @@ For more extensive info, see the windows build instructions `docs/build.rst`.
|
||||||
* `python test.py` runs the tests on Pillow in all the virtual envs.
|
* `python test.py` runs the tests on Pillow in all the virtual envs.
|
||||||
* Currently working with zlib, libjpeg, freetype, and libtiff on Python 2.7, 3.3, and 3.4, both 32 and 64 bit, on a local win7 pro machine and appveyor.com
|
* Currently working with zlib, libjpeg, freetype, and libtiff on Python 2.7, 3.3, and 3.4, both 32 and 64 bit, on a local win7 pro machine and appveyor.com
|
||||||
* Webp is built, not detected.
|
* Webp is built, not detected.
|
||||||
* LCMS and OpenJpeg are not building.
|
* LCMS, OpenJpeg and libimagequant are not building.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user