code: def test_update_endpoint_no_instance_type_or_no_instance_count():
      sagemaker_session = empty_sagemaker_session()
      predictor = Predictor(
          ENDPOINT, sagemaker_session=sagemaker_session
      )
  
      bad_args = (
          {"instance_type": "ml.c4.xlarge"},
          {"initial_instance_count": 2},
      )
      for args in bad_args:
          with pytest.raises(ValueError) as exception:
              predictor.update_endpoint(**args)
  
          expected_msg = (
              "Missing initial_instance_count and/or instance_type."
          )
          assert expected_msg in str(exception.value)
  
imports: from __future__ import absolute_import
  import io
  import json
  import pytest
  from mock import Mock, call, patch
  from sagemaker.deserializers import CSVDeserializer, PandasDeserializer
  from sagemaker.enums import EndpointType
  from sagemaker.model_monitor.model_monitoring import DEFAULT_REPOSITORY_NAME
  from sagemaker.predictor import Predictor
  from sagemaker.serializers import JSONSerializer, CSVSerializer
  from sagemaker.compute_resource_requirements.resource_requirements import ResourceRequirements
label_desc: Use image node_id 14 for calling a global function with example usage: test_update_endpoint_no_instance_type_or_no_instance_count() without return types