code: def test_check_experiment_status_failed():
      content = "some_failed_status"
      error = "NNI_ERROR"
      with pytest.raises(RuntimeError) as excinfo:
          with patch(
              "requests.get",
              side_effect=lambda url: mocked_status_get(
                  url, content, error
              ),
          ):
              check_experiment_status(wait=0.1, max_retries=1)
      assert (
          "NNI experiment failed to complete with status some_failed_status - NNI_ERROR"
          == str(excinfo.value)
      )
  
imports: import os
  import sys
  import json
  import pytest
  from unittest.mock import patch
  from tempfile import TemporaryDirectory
  from recommenders.tuning.nni.nni_utils import get_experiment_status, check_experiment_status, check_stopped, check_metrics_written, get_trials, NNI_STATUS_URL, NNI_TRIAL_JOBS_URL
label_desc: Use image node_id 9 for calling a global function with example usage: test_check_experiment_status_failed() without return types