Merge pull request #1027 from hugovk/landscape_fixes

Some landscape.io fixes
This commit is contained in:
wiredfool 2014-11-27 12:46:00 -08:00
commit 5f7c2dadc4
4 changed files with 15 additions and 10 deletions

View File

@ -20,7 +20,6 @@
from PIL import Image from PIL import Image
from PIL._util import isStringType from PIL._util import isStringType
import operator import operator
import math
from functools import reduce from functools import reduce

View File

@ -227,3 +227,9 @@ class TestBoxBlur(PillowTestCase):
passes=3, passes=3,
delta=1, delta=1,
) )
if __name__ == '__main__':
unittest.main()
# End of file

View File

@ -30,9 +30,9 @@ class TestFileGif(PillowTestCase):
def test_grayscale(optimize): def test_grayscale(optimize):
im = Image.new("L", (1, 1), 0) im = Image.new("L", (1, 1), 0)
file = BytesIO() filename = BytesIO()
im.save(file, "GIF", optimize=optimize) im.save(filename, "GIF", optimize=optimize)
return len(file.getvalue()) return len(filename.getvalue())
def test_bilevel(optimize): def test_bilevel(optimize):
im = Image.new("1", (1, 1), 0) im = Image.new("1", (1, 1), 0)