def test_move_current_health_is_less(self): # Arrange name = 'NShip' type_ = 'Battle' align = 'us' x_location = 2 y_location = 2 # Act ship = Ship(name, type_, x_location, y_location, align) ship._max_health = 100 ship._current_health = 90 ship.move() print(ship._current_health) # Assert self.assertNotEqual(90, ship._current_health) # 90 and 91 won't be equal
def test_move_current_health_is_max(self): # Arrange name = 'NShip' type_ = 'Battle' align = 'us' x_location = 2 y_location = 2 # Act ship = Ship(name, type_, x_location, y_location, align) ship._max_health = 100 ship._current_health = 100 ship.move() print(ship._current_health) # Assert self.assertEqual( 100, ship._current_health) # current health = max health - so equal