code: def test_update_deployment_resource_instance(
      mock_update_deployment: MagicMock,
      mock_get: MagicMock,
      update_schema: UpdateDeploymentSchema,
      get_schema: DeploymentSchema,
      cloudclient: BentoCloudClient,
  ):
      mock_update_deployment.side_effect = f_update
      mock_get.return_value = get_schema
      res = cloudclient.deployment.update(
          deployment_name="test-xxx",
          cluster_name="",
          kube_namespace="",
          resource_instance="test-resource",
      )
      update_schema.targets[
          0
      ].config.resource_instance = "test-resource"
      for _, v in update_schema.targets[0].config.runners.items():
          v.resource_instance = "test-resource"
      assert res == update_schema
  
imports: from __future__ import annotations
  import typing
  from datetime import datetime
  from unittest.mock import patch
  import attr
  import pytest
  from bentoml._internal.cloud.schemas import BentoFullSchema
  from bentoml._internal.cloud.schemas import BentoImageBuildStatus
  from bentoml._internal.cloud.schemas import BentoManifestSchema
  from bentoml._internal.cloud.schemas import BentoRepositorySchema
  from bentoml._internal.cloud.schemas import BentoUploadStatus
  from bentoml._internal.cloud.schemas import ClusterSchema
  from bentoml._internal.cloud.schemas import CreateDeploymentSchema
  from bentoml._internal.cloud.schemas import CreateDeploymentTargetSchema
  from bentoml._internal.cloud.schemas import DeploymentMode
  from bentoml._internal.cloud.schemas import DeploymentRevisionSchema
  from bentoml._internal.cloud.schemas import DeploymentRevisionStatus
  from bentoml._internal.cloud.schemas import DeploymentSchema
  from bentoml._internal.cloud.schemas import DeploymentStatus
  from bentoml._internal.cloud.schemas import DeploymentTargetCanaryRule
  from bentoml._internal.cloud.schemas import DeploymentTargetCanaryRuleType
  from bentoml._internal.cloud.schemas import DeploymentTargetConfig
  from bentoml._internal.cloud.schemas import DeploymentTargetHPAConf
  from bentoml._internal.cloud.schemas import DeploymentTargetRunnerConfig
  from bentoml._internal.cloud.schemas import DeploymentTargetSchema
  from bentoml._internal.cloud.schemas import DeploymentTargetType
  from bentoml._internal.cloud.schemas import LabelItemSchema
  from bentoml._internal.cloud.schemas import ResourceType
  from bentoml._internal.cloud.schemas import UpdateDeploymentSchema
  from bentoml._internal.cloud.schemas import UserSchema
  from bentoml.cloud import BentoCloudClient
  from bentoml.cloud import Resource
label_desc: Use image node_id 24 for calling a global function with example usage: test_update_deployment_resource_instance(mock_update_deployment, mock_get, update_schema, get_schema, cloudclient) without return types