Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
itzpr3d4t0r committed Jul 13, 2024
1 parent d318211 commit 64b425d
Showing 1 changed file with 40 additions and 5 deletions.
45 changes: 40 additions & 5 deletions test/test_circle.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,16 @@ def test_top(self):
"""Ensures changing the top attribute moves the circle and does not change the circle's radius."""
expected_radius = 5.0

for pos in [(1, 0), (0, 0), (-1, 0), (0, -1), (1, 1), (-1, -1), (-1, 1), (1, -1)]:
for pos in [
(1, 0),
(0, 0),
(-1, 0),
(0, -1),
(1, 1),
(-1, -1),
(-1, 1),
(1, -1),
]:
c = Circle((0, 0), expected_radius)

c.top = pos
Expand Down Expand Up @@ -336,7 +345,16 @@ def test_left(self):
"""Ensures changing the left attribute moves the circle and does not change the circle's radius."""
expected_radius = 5.0

for pos in [(1, 0), (0, 0), (-1, 0), (0, -1), (1, 1), (-1, -1), (-1, 1), (1, -1)]:
for pos in [
(1, 0),
(0, 0),
(-1, 0),
(0, -1),
(1, 1),
(-1, -1),
(-1, 1),
(1, -1),
]:
c = Circle((0, 0), expected_radius)

c.left = pos
Expand Down Expand Up @@ -378,7 +396,16 @@ def test_right(self):
"""Ensures changing the right attribute moves the circle and does not change the circle's radius."""
expected_radius = 5.0

for pos in [(1, 0), (0, 0), (-1, 0), (0, -1), (1, 1), (-1, -1), (-1, 1), (1, -1)]:
for pos in [
(1, 0),
(0, 0),
(-1, 0),
(0, -1),
(1, 1),
(-1, -1),
(-1, 1),
(1, -1),
]:
c = Circle((0, 0), expected_radius)

c.right = pos
Expand Down Expand Up @@ -420,7 +447,16 @@ def test_bottom(self):
"""Ensures changing the bottom attribute moves the circle and does not change the circle's radius."""
expected_radius = 5.0

for pos in [(1, 0), (0, 0), (-1, 0), (0, -1), (1, 1), (-1, -1), (-1, 1), (1, -1)]:
for pos in [
(1, 0),
(0, 0),
(-1, 0),
(0, -1),
(1, 1),
(-1, -1),
(-1, 1),
(1, -1),
]:
c = Circle((0, 0), expected_radius)

c.bottom = pos
Expand Down Expand Up @@ -458,7 +494,6 @@ def test_bottom_del(self):
with self.assertRaises(AttributeError):
del c.bottom


def test_area(self):
"""Ensures the area is calculated correctly."""
c = Circle(0, 0, 1)
Expand Down

0 comments on commit 64b425d

Please sign in to comment.