code: def test_fail():
      image = np.zeros((50, 100))
      labels = np.zeros((50, 100), int)
      labels[20:40, 51:62] = 1
      workspace, module = make_workspace(image, labels)
      assert isinstance(
          module, cellprofiler.modules.definegrid.DefineGrid
      )
      assert isinstance(
          workspace, cellprofiler_core.workspace.Workspace
      )
      module.ordering.value = (
          cellprofiler.modules.definegrid.NUM_BY_COLUMNS
      )
      module.auto_or_manual.value = (
          cellprofiler.modules.definegrid.AM_AUTOMATIC
      )
      module.wants_image.value = True
      with pytest.raises(RuntimeError):
          module.run(workspace)
  
file_path: CellProfiler/tests/frontend/modules/test_definegrid.py
imports: import numpy
  import pytest
  import cellprofiler_core.utilities.grid
  import cellprofiler_core.image
  import cellprofiler_core.measurement
  import cellprofiler.modules.definegrid
  import cellprofiler_core.object
  import cellprofiler_core.pipeline
  import cellprofiler_core.workspace
label_desc: Use image node_id 3 for calling a global function with example usage: test_fail() without return types