def test_remove_friend(self): """ Tests that the remove_friend() function removes the specified person to the set Takes a Person, friendToRemove and returns True if the specified friend was removed from the set or False if it wasn't """ friendToRemove = Network.friend_to_remove(self, "Vanessa", 18) Network.remove_friend(self, friendToRemove) #check that the friend was removed from the set self.assertTrue(friendToRemove is not Network.setOfFriends)
def test_remove_friend(self, friendToRemove): """ Tests that the remove_friend() function removes the specified person to the set Takes a Person, friendToRemove and returns True if the specified friend was removed from the set or False if it wasn't """ Network.remove_friend(self, friendToRemove) #check that the friend was removed from the set if (Network.setOfFriends.__contains__(friendToRemove)): return False else: return True return