def test_delete_first_occurence_empty_list(self): l = LinkedList() original_python_list = l.to_python_list() l.deleteFirstOccurence(7) modified_python_list = l.to_python_list() self.assertEqual(original_python_list, modified_python_list)
def test_delete_first_occurence(self): l = LinkedList([1, 2, 2, 3]) l.deleteFirstOccurence(2) self.assertEqual(l.to_python_list(), [1, 2, 3])