fix test Square isinstance of Square and Rectangle (#2)

This commit is contained in:
kieranaustin 2021-02-04 02:09:26 +01:00 committed by GitHub
parent f6011db280
commit 7071e7231a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,7 +18,7 @@ class UnitTests(unittest.TestCase):
self.assertEqual(actual, expected, 'Expected Square class to be a distinct class from the Rectangle class.')
def test_square_is_square_and_rectangle(self):
actual = isinstance(self.sq, shape_calculator.Square) and isinstance(self.sq, shape_calculator.Square)
actual = isinstance(self.sq, shape_calculator.Square) and isinstance(self.sq, shape_calculator.Rectangle)
expected = True
self.assertEqual(actual, expected, 'Expected square object to be an instance of the Square class and the Rectangle class.')
@ -112,4 +112,4 @@ class UnitTests(unittest.TestCase):
self.assertEqual(actual, expected, 'Expected `get_amount_inside` to return 0.')
if __name__ == "__main__":
unittest.main()
unittest.main()