code: def test_arr_like(
      funcname,
      shape,
      cast_shape,
      dtype,
      cast_chunks,
      chunks,
      name,
      order,
      backend,
  ):
      backend_lib = pytest.importorskip(backend)
      with dask.config.set({"array.backend": backend}):
          np_func = getattr(backend_lib, funcname)
          da_func = getattr(da, funcname)
          shape = cast_shape(shape)
          chunks = cast_chunks(chunks)
  
          if "full" in funcname:
              old_np_func = np_func
              old_da_func = da_func
  
              np_func = lambda *a, **k: old_np_func(
                  *a, fill_value=5, **k
              )
              da_func = lambda *a, **k: old_da_func(
                  *a, fill_value=5, **k
              )
  
          dtype = np.dtype(dtype)
  
          if "like" in funcname:
              a = backend_lib.random.randint(0, 10, shape).astype(dtype)
  
              np_r = np_func(a, order=order)
              da_r = da_func(a, order=order, chunks=chunks, name=name)
          else:
              np_r = np_func(shape, order=order, dtype=dtype)
              da_r = da_func(
                  shape,
                  order=order,
                  dtype=dtype,
                  chunks=chunks,
                  name=name,
              )
  
          assert np_r.shape == da_r.shape
          assert np_r.dtype == da_r.dtype
  
          # Make sure we are using the desired backend
          assert isinstance(da_r._meta, backend_lib.ndarray)
          assert isinstance(da_r.compute(), backend_lib.ndarray)
  
          if "empty" not in funcname:
              assert_eq(np_r, da_r)
  
          if name is None:
              assert funcname.split("_")[0] in da_r.name
          else:
              assert da_r.name == name
  
          if "order" == "F":
              assert np.isfortran(da_r.compute())
          else:
              assert not np.isfortran(da_r.compute())
  
imports: from __future__ import annotations
  import pytest
  import numpy
  import pytest
  from tlz import concat
  import dask
  import dask.array
  from dask.array.core import normalize_chunks
  from dask.array.numpy_compat import AxisError
  from dask.array.utils import assert_eq, same_keys
label_desc: Use image node_id 1 for calling a global function with example usage: test_arr_like(funcname, shape, cast_shape, dtype, cast_chunks, chunks, name, order, backend) without return types