code: def test_with_arg_overwrites_with_kwarg_collisions_without_config(
      self,
      mock_get_model_specs: mock.Mock,
      mock_session: mock.Mock,
      mock_resolve_value_from_config: mock.Mock,
      mock_get_sagemaker_config_value: mock.Mock,
      mock_retrieve_kwargs: mock.Mock,
      mock_model_retrieve_kwargs: mock.Mock,
      mock_estimator_init: mock.Mock,
      mock_estimator_deploy: mock.Mock,
      mock_is_valid_model_id: mock.Mock,
  ):
      mock_estimator_deploy.return_value = default_predictor
  
      mock_is_valid_model_id.return_value = True
  
      model_id, _ = "js-trainable-model", "*"
  
      mock_retrieve_kwargs.return_value = {
          "enable_network_isolation": metadata_enable_network_isolation,
          "encrypt_inter_container_traffic": metadata_intercontainer_encryption,
      }
  
      mock_get_sagemaker_config_value.return_value = None
  
      mock_resolve_value_from_config.side_effect = (
          resolve_value_from_config
      )
      mock_get_model_specs.side_effect = get_special_model_spec
  
      mock_session.return_value = sagemaker_session
  
      estimator = JumpStartEstimator(
          model_id=model_id,
          role=override_role,
          enable_network_isolation=override_enable_network_isolation,
          encrypt_inter_container_traffic=override_encrypt_inter_container_traffic,
      )
  
      self.assertEquals(mock_get_sagemaker_config_value.call_count, 1)
      self.assertEquals(
          mock_estimator_init.call_args[1].get("role"), override_role
      )
      self.assertEquals(
          mock_estimator_init.call_args[1].get(
              "enable_network_isolation"
          ),
          override_enable_network_isolation,
      )
      self.assertEquals(
          mock_estimator_init.call_args[1].get(
              "encrypt_inter_container_traffic"
          ),
          override_encrypt_inter_container_traffic,
      )
  
      mock_model_retrieve_kwargs.return_value = {
          "enable_network_isolation": metadata_inference_enable_network_isolation,
      }
  
      estimator.deploy(
          role=override_inference_role,
          enable_network_isolation=override_inference_enable_network_isolation,
      )
  
      self.assertEquals(mock_get_sagemaker_config_value.call_count, 3)
  
      self.assertEquals(
          mock_estimator_deploy.call_args[1].get("role"),
          override_inference_role,
      )
  
      self.assertEquals(
          mock_estimator_deploy.call_args[1].get(
              "enable_network_isolation"
          ),
          override_inference_enable_network_isolation,
      )
  
imports: from __future__ import absolute_import
  import random
  from unittest import mock
  import unittest
  from sagemaker.base_predictor import Predictor
  from sagemaker.config.config_schema import MODEL_ENABLE_NETWORK_ISOLATION_PATH, MODEL_EXECUTION_ROLE_ARN_PATH, TRAINING_JOB_ENABLE_NETWORK_ISOLATION_PATH, TRAINING_JOB_INTER_CONTAINER_ENCRYPTION_PATH, TRAINING_JOB_ROLE_ARN_PATH
  from sagemaker.jumpstart.constants import DEFAULT_JUMPSTART_SAGEMAKER_SESSION
  from sagemaker.jumpstart.estimator import JumpStartEstimator
  from sagemaker.session import Session
  from sagemaker.utils import resolve_value_from_config
  from tests.unit.sagemaker.jumpstart.utils import get_special_model_spec
label_desc: Use image node_id 7 for calling the IntelligentDefaultsEstimatorTest obj's underlying member method code with example usage: obj.test_with_arg_overwrites_with_kwarg_collisions_without_config(mock_get_model_specs, mock_session, mock_resolve_value_from_config, mock_get_sagemaker_config_value, mock_retrieve_kwargs, mock_model_retrieve_kwargs, mock_estimator_init, mock_estimator_deploy, mock_is_valid_model_id) without return types