code: def test_reordered_domain():
      incs, outcs, map, inv = voxel_to_world()
      cm = CoordinateMap(incs, outcs, map, inv)
      recm = cm.reordered_domain("jki")
      assert recm.function_domain.coord_names == ("j", "k", "i")
      assert recm.function_range.coord_names == outcs.coord_names
      assert recm.function_domain.name == incs.name
      assert recm.function_range.name == outcs.name
      # default reverse reorder
      recm = cm.reordered_domain()
      assert recm.function_domain.coord_names == ("k", "j", "i")
      # reorder with order as indices
      recm = cm.reordered_domain([2, 0, 1])
      assert recm.function_domain.coord_names == ("k", "i", "j")
  
imports: from copy import copy
  from types import SimpleNamespace
  import numpy
  from ..coordinate_map import AffineTransform, AxisError, CoordinateMap, CoordMapMaker, CoordMapMakerError, _as_coordinate_map, _fix0, append_io_dim, axmap, compose, drop_io_dim, equivalent, input_axis_index, io_axis_indices, orth_axes, product, shifted_domain_origin, shifted_range_origin
  from ..coordinate_system import CoordinateSystem, CoordinateSystemError, CoordSysMaker
  import pytest
  from numpy.testing import assert_almost_equal, assert_array_equal
label_desc: Use image node_id 25 for calling a global function with example usage: test_reordered_domain() without return types