code: def test_variable_type():
      with TemporaryDirectory() as out_dir:
          open(pjoin(out_dir, "test"), "w").close()
          open(pjoin(out_dir, "test1"), "w").close()
          open(pjoin(out_dir, "test2"), "w").close()
  
          sys.argv = [sys.argv[0]]
          pos_results = [
              pjoin(out_dir, "test"),
              pjoin(out_dir, "test1"),
              pjoin(out_dir, "test2"),
              12,
          ]
          inputs = inputs_from_results(pos_results)
          sys.argv.extend(inputs)
          dcwf = DummyVariableTypeWorkflow()
          _, positional_res, positional_res2 = run_flow(dcwf)
          npt.assert_equal(positional_res2, 12)
  
          for k, v in zip(positional_res, pos_results[:-1]):
              npt.assert_equal(k, v)
  
          dcwf = DummyVariableTypeErrorWorkflow()
          npt.assert_raises(ValueError, run_flow, dcwf)
  
file_path: dipy/dipy/workflows/tests/test_iap.py
imports: import sys
  from os.path import join
  from tempfile import TemporaryDirectory
  import numpy.testing
  from dipy.workflows.base import IntrospectiveArgumentParser, none_or_dtype
  from dipy.workflows.flow_runner import run_flow
  from dipy.workflows.tests.workflow_tests_utils import DummyFlow, DummyCombinedWorkflow, DummyWorkflow1, DummyWorkflowOptionalStr, DummyVariableTypeWorkflow, DummyVariableTypeErrorWorkflow
label_desc: Use image node_id 2 for calling a global function with example usage: test_variable_type() without return types