Skip to content

Commit

Permalink
Updated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
radarhere committed Feb 19, 2020
1 parent 2e02500 commit 2a75de2
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions Tests/test_imagechops.py
Original file line number Diff line number Diff line change
Expand Up @@ -363,10 +363,10 @@ def test_subtract_modulo_no_clip():
new = ImageChops.subtract_modulo(im1, im2)

# Assert
self.assertEqual(new.getpixel((50, 50)), (241, 167, 127))
assert new.getpixel((50, 50)) == (241, 167, 127)


def test_soft_light(self):
def test_soft_light():
# Arrange
im1 = Image.open("Tests/images/hopper.png")
im2 = Image.open("Tests/images/hopper-XYZ.png")
Expand All @@ -375,11 +375,11 @@ def test_soft_light(self):
new = ImageChops.soft_light(im1, im2)

# Assert
self.assertEqual(new.getpixel((64, 64)), (163, 54, 32))
self.assertEqual(new.getpixel((15, 100)), (1, 1, 3))
assert new.getpixel((64, 64)) == (163, 54, 32)
assert new.getpixel((15, 100)) == (1, 1, 3)


def test_hard_light(self):
def test_hard_light():
# Arrange
im1 = Image.open("Tests/images/hopper.png")
im2 = Image.open("Tests/images/hopper-XYZ.png")
Expand All @@ -388,11 +388,11 @@ def test_hard_light(self):
new = ImageChops.hard_light(im1, im2)

# Assert
self.assertEqual(new.getpixel((64, 64)), (144, 50, 27))
self.assertEqual(new.getpixel((15, 100)), (1, 1, 2))
assert new.getpixel((64, 64)) == (144, 50, 27)
assert new.getpixel((15, 100)) == (1, 1, 2)


def test_overlay(self):
def test_overlay():
# Arrange
im1 = Image.open("Tests/images/hopper.png")
im2 = Image.open("Tests/images/hopper-XYZ.png")
Expand All @@ -401,8 +401,8 @@ def test_overlay(self):
new = ImageChops.overlay(im1, im2)

# Assert
self.assertEqual(new.getpixel((64, 64)), (159, 50, 27))
self.assertEqual(new.getpixel((15, 100)), (1, 1, 2))
assert new.getpixel((64, 64)) == (159, 50, 27)
assert new.getpixel((15, 100)) == (1, 1, 2)


def test_logical():
Expand Down

0 comments on commit 2a75de2

Please sign in to comment.