Esempio n. 1
0
 def test_append_empty_list_to_list(self):
     self.assertEqual(append([1, 2, 3, 4], []), [1, 2, 3, 4])
Esempio n. 2
0
 def test_append_non_empty_lists(self):
     self.assertEqual(append([1, 2], [2, 3, 4, 5]), [1, 2, 2, 3, 4, 5])
Esempio n. 3
0
 def test_append_to_empty(self):
     self.assertEqual([42], list_ops.append([], 42))
Esempio n. 4
0
 def test_append_empty_lists(self):
     self.assertEqual(append([], []), [])
Esempio n. 5
0
 def test_append_tuple(self):
     self.assertEqual(["10", "python", "hello"],
                      list_ops.append(["10", "python"], "hello"))
Esempio n. 6
0
 def test_append_range(self):
     self.assertEqual([100, range(1000)], list_ops.append([100],
                                                          range(1000)))
 def test_append_nonempty_lists(self):
     self.assertEqual(list_ops.append([1, 2], [2, 3, 4, 5]),
                      [1, 2, 2, 3, 4, 5])
Esempio n. 8
0
 def test_append_empty_list_to_list(self):
     self.assertEqual(list_ops.append([], [1, 2, 3, 4]), [1, 2, 3, 4])
 def test_append_empty_list_to_list(self):
     self.assertEqual(list_ops.append([], [1, 2, 3, 4]), [1, 2, 3, 4])
 def test_append_empty_lists(self):
     self.assertEqual(list_ops.append([], []), [])
Esempio n. 11
0
 def test_append_to_empty(self):
     self.assertEqual([42], list_ops.append([], 42))
Esempio n. 12
0
 def test_append_range(self):
     self.assertEqual([100, range(1000)], list_ops.append([100], range(1000)))
Esempio n. 13
0
 def test_append_tuple(self):
     self.assertEqual(
         ["10", "python", "hello"],
         list_ops.append(["10", "python"], "hello")
     )