def test_flatten_nested_lists_plain(self): """Test source.flatten_nested_lists([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]) """ l = expected = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12] self.assertEqual(source.flatten_nested_lists(l), expected)
def test_flatten_nested_lists(self): """Test source.flatten_nested_lists([1, 2, [3, 4, [[5, 6], 7], 8, 9, 10], 11, 12]) """ l = [1, 2, [3, 4, [[5, 6], 7], 8, 9, 10], 11, 12] expected = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12] self.assertEqual(source.flatten_nested_lists(l), expected)