code: def test_reg_measure():
      """tests for reg_measure interface"""
      # Create a reg_measure object
      nr_measure = RegMeasure()
  
      # Check if the command is properly defined
      assert nr_measure.cmd == get_custom_path("reg_measure")
  
      # test raising error with mandatory args absent
      with pytest.raises(ValueError):
          nr_measure.run()
  
      # Assign some input data
      ref_file = example_data("im1.nii")
      flo_file = example_data("im2.nii")
      nr_measure.inputs.ref_file = ref_file
      nr_measure.inputs.flo_file = flo_file
      nr_measure.inputs.measure_type = "lncc"
      nr_measure.inputs.omp_core_val = 4
  
      cmd_tmp = "{cmd} -flo {flo} -lncc -omp 4 -out {out} -ref {ref}"
      expected_cmd = cmd_tmp.format(
          cmd=get_custom_path("reg_measure"),
          flo=flo_file,
          out="im2_lncc.txt",
          ref=ref_file,
      )
  
      assert nr_measure.cmdline == expected_cmd
  
file_path: nipype/nipype/interfaces/niftyreg/tests/test_regutils.py
imports: import os
  import pytest
  from ....utils.filemanip import which
  from ....testing import example_data
  from ..None import get_custom_path, RegAverage, RegResample, RegJacobian, RegTools, RegMeasure, RegTransform
label_desc: Use image node_id 7 for calling a global function with example usage: test_reg_measure() without return types