code: def test_holes_no_holes():
      for wants_fill_holes in (True, False):
          for method in (
              cellprofiler.modules.identifysecondaryobjects.M_DISTANCE_B,
              cellprofiler.modules.identifysecondaryobjects.M_PROPAGATION,
              cellprofiler.modules.identifysecondaryobjects.M_WATERSHED_G,
              cellprofiler.modules.identifysecondaryobjects.M_WATERSHED_I,
          ):
              labels = numpy.zeros((20, 10), int)
              labels[5, 5] = 1
              labels[15, 5] = 2
              threshold = numpy.zeros((20, 10), bool)
              threshold[1:7, 4:7] = True
              threshold[2, 5] = False
              threshold[14:17, 4:7] = True
              expected = numpy.zeros((20, 10), int)
              expected[1:7, 4:7] = 1
              expected[14:17, 4:7] = 2
              if not wants_fill_holes:
                  expected[2, 5] = 0
              workspace, module = make_workspace(
                  threshold * 0.5, labels
              )
              assert isinstance(
                  module,
                  cellprofiler.modules.identifysecondaryobjects.IdentifySecondaryObjects,
              )
              module.threshold.threshold_scope.value = (
                  cellprofiler.modules.threshold.TS_GLOBAL
              )
              module.threshold.global_operation.value = (
                  cellprofiler.modules.threshold.TM_MANUAL
              )
              module.threshold.manual_threshold.value = 0.5
              module.method.value = method
              module.fill_holes.value = wants_fill_holes
              module.distance_to_dilate.value = 10000
              image_set = workspace.image_set
              assert isinstance(
                  image_set, cellprofiler_core.image.ImageSet
              )
  
              module.run(workspace)
              object_out = workspace.object_set.get_objects(
                  OUTPUT_OBJECTS_NAME
              )
              labels_out = object_out.segmented
              indexes = workspace.measurements.get_current_measurement(
                  OUTPUT_OBJECTS_NAME, "Parent_" + INPUT_OBJECTS_NAME
              )
              assert len(indexes) == 2
              indexes = numpy.hstack(([0], indexes))
              assert numpy.all(indexes[labels_out] == expected)
  
imports: import io
  import centrosome.threshold
  import numpy
  from cellprofiler_core.constants.measurement import FF_COUNT, COLTYPE_FLOAT, COLTYPE_INTEGER, R_FIRST_IMAGE_NUMBER, R_SECOND_IMAGE_NUMBER, R_FIRST_OBJECT_NUMBER, R_SECOND_OBJECT_NUMBER
  from cellprofiler_core.constants.module._identify import TS_GLOBAL, O_TWO_CLASS, O_FOREGROUND
  import tests.frontend.modules
  import cellprofiler_core.image
  import cellprofiler_core.measurement
  import cellprofiler.modules.identifysecondaryobjects
  import cellprofiler.modules.threshold
  import cellprofiler_core.object
  import cellprofiler_core.pipeline
  import cellprofiler_core.preferences
  import cellprofiler_core.workspace
label_desc: Use image node_id 23 for calling a global function with example usage: test_holes_no_holes() without return types