code: def candidate_mock(sagemaker_session):
      candidate = Mock(
          name="candidate_mock",
          containers=INFERENCE_CONTAINERS,
          steps=CANDIDATE_STEPS,
          sagemaker_session=sagemaker_session,
      )
      return candidate
  
imports: from __future__ import absolute_import
  import copy
  import pytest
  from mock import Mock, patch
  from sagemaker import AutoML, AutoMLJob, AutoMLInput, CandidateEstimator, PipelineModel
  from sagemaker.predictor import Predictor
  from sagemaker.session_settings import SessionSettings
  from sagemaker.workflow.functions import Join
  from tests.unit import SAGEMAKER_CONFIG_AUTO_ML, SAGEMAKER_CONFIG_TRAINING_JOB, _test_default_bucket_and_prefix_combinations, DEFAULT_S3_BUCKET_NAME, DEFAULT_S3_OBJECT_KEY_PREFIX_NAME
label_desc: Use image node_id 3 for calling a global function with example usage: candidate_mock(sagemaker_session) and returns: candidate