code: def runner(Parser):
      if Parser != _shell_utils.NativeParser:
          pytest.skip("Unable to run with non-native parser")
  
      if Parser == _shell_utils.WindowsParser:
          return lambda cmd: subprocess.check_output(cmd)
      elif Parser == _shell_utils.PosixParser:
          # posix has no non-shell string parsing
          return lambda cmd: subprocess.check_output(cmd, shell=True)
      else:
          raise NotImplementedError
  
file_path: catboost/contrib/python/numpy/py3/numpy/distutils/tests/test_shell_utils.py
imports: import pytest
  import subprocess
  import json
  import sys
  from numpy.distutils import _shell_utils
  from numpy.testing import IS_WASM
label_desc: Use image node_id 2 for calling a global function with example usage: runner(Parser) and returns: function, function