code: def test_basic_nd():
      for dimension in (3, 4, 5):
          shape = (5,) * dimension
          hypercube = np.zeros(shape)
          slice_mid = tuple(
              slice(1, -1, None) for dim in range(dimension)
          )
          hypercube[slice_mid] = 1  # sum is 3**dimension
          filled = flood_fill(hypercube, (2,) * dimension, 2)
  
          # Test that the middle sum is correct
          assert filled.sum() == 3**dimension * 2
  
          # Test that the entire array is as expected
          np.testing.assert_equal(
              filled,
              np.pad(np.ones((3,) * dimension) * 2, 1, "constant"),
          )
  
file_path: scikit-image/skimage/morphology/tests/test_flood_fill.py
imports: import numpy
  import pytest
  from skimage.morphology import flood, flood_fill
label_desc: Use image node_id 12 for calling a global function with example usage: test_basic_nd() without return types