code: def test_version_parsefail_mocked(mock_run):
      mock_run.return_value = subprocess.CompletedProcess(
          _common.INVALID_CMD,
          returncode=0,
          stdout="nonversioninfo",
          stderr=None,
      )
  
      with pytest.raises(RuntimeError, match=r"nonversioninfo"):
          graphviz.version()
  
      mock_run.assert_called_once_with(
          [_common.EXPECTED_DOT_BINARY, "-V"],
          stdout=subprocess.PIPE,
          stderr=subprocess.STDOUT,
          startupinfo=_common.StartupinfoMatcher(),
          encoding="ascii",
      )
  
imports: import subprocess
  import pytest
  import graphviz
  import _common
label_desc: Use image node_id 3 for calling a global function with example usage: test_version_parsefail_mocked(mock_run) without return types