def test_remove_list(self): test_list_server1 = ListServer() p1 = Product('abc33', 444.4) test_list_server1.catalog.append(p1) self.assertTrue(True, test_list_server1.remove_product('abc33')) self.assertEqual([], test_list_server1.catalog)
from product import Product from server import ListServer new_prod = Product('3adf', 333.3) new_prod.name = '33rt' test_list_server = ListServer() p1 = Product('abc33', 444.4) test_list_server.catalog.append(p1) test_list_server.remove_product('abc33') test_server_2 = ListServer()