예제 #1
0
 def test_remove_adjacent_in_middle(self):
     self.assertEqual([1, 2, 3], list2.remove_adjacent([1, 2, 2, 3]))
예제 #2
0
 def test_remove_multiple_adjacent_from_empty(self):
     self.assertEqual([], list2.remove_adjacent([]))
예제 #3
0
 def test_remove_adjacent_at_end(self):
     self.assertEqual([1, 3], list2.remove_adjacent([1, 3, 3]))
예제 #4
0
 def test_remove_multiple_adjacent_groups(self):
     self.assertEqual([1, 2, 3],
                      list2.remove_adjacent([1, 1, 2, 2, 2, 3, 3, 3]))
예제 #5
0
 def test_remove_adjacent_at_start(self):
     self.assertEqual([2, 3], list2.remove_adjacent([2, 2, 2, 3]))