code: def test_invalid_out(func, out):
      if func is shapely.points:
          x = [[0.2, 0.3], [0.4, 0.5]]
          indices = [0, 2]
      elif func is shapely.linestrings:
          x = [[1, 1], [2, 1], [2, 2], [3, 3], [3, 4], [4, 4]]
          indices = [0, 0, 0, 2, 2, 2]
      else:
          x = [point, line_string]
          indices = [0, 2]
      with pytest.raises((TypeError, ValueError)):
          func(x, indices=indices, out=out)
  
imports: import numpy
  import pytest
  from numpy.testing import assert_array_equal
  import shapely
  from shapely import LinearRing, Polygon
  from shapely.testing import assert_geometries_equal
  from shapely.tests.common import empty_point, line_string, linear_ring, point, polygon
label_desc: Use image node_id 4 for calling a global function with example usage: test_invalid_out(func, out) without return types