Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
orlnub123 authored and radarhere committed Feb 16, 2020
1 parent 2e716de commit 64c08f4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Tests/test_image_thumbnail.py
Expand Up @@ -34,14 +34,14 @@ def test_aspect():
im.thumbnail((100, 100))
assert im.size == (100, 50)

im = Image.new("L", (256, 128))
im.thumbnail((100, 50))
assert im.size == (100, 50)

im = Image.new("L", (64, 64))
im.thumbnail((100, 100))
assert im.size == (64, 64)

im = Image.new("L", (128, 128))
im.thumbnail((100, 100))
assert im.size == (100, 100)

im = Image.new("L", (256, 162)) # ratio is 1.5802469136
im.thumbnail((33, 33))
assert im.size == (33, 21) # ratio is 1.5714285714
Expand All @@ -52,7 +52,7 @@ def test_aspect():

im = Image.new("L", (145, 100)) # ratio is 1.45
im.thumbnail((50, 50))
assert im.size ==(50, 34) # ratio is 1.47058823529
assert im.size == (50, 34) # ratio is 1.47058823529

im = Image.new("L", (100, 145)) # ratio is 0.689655172414
im.thumbnail((50, 50))
Expand All @@ -62,7 +62,7 @@ def test_aspect():
def test_float():
im = Image.new("L", (128, 128))
im.thumbnail((99.9, 99.9))
assert im.size == (100, 100)
assert im.size == (99, 99)


def test_no_resize():
Expand Down

0 comments on commit 64c08f4

Please sign in to comment.