code: def test_get_r2_client_region_name_set_correctly(r2_artifact_root):
      region_name = "us_random_region_42"
      with mock.patch("boto3.client") as mock_get_s3_client:
          s3_client_mock = mock.Mock()
          mock_get_s3_client.return_value = s3_client_mock
          s3_client_mock.get_bucket_location.return_value = {
              "LocationConstraint": region_name
          }
  
          artifact_uri = posixpath.join(r2_artifact_root, "some/path")
          repo = get_artifact_repository(artifact_uri)
          repo._get_s3_client()
  
          mock_get_s3_client.assert_called_with(
              "s3",
              config=ANY,
              endpoint_url=ANY,
              verify=None,
              aws_access_key_id=None,
              aws_secret_access_key=None,
              aws_session_token=None,
              region_name=region_name,
          )
  
file_path: mlflow/tests/store/artifact/test_r2_artifact_repo.py
imports: import posixpath
  from unittest import mock
  from unittest.mock import ANY
  import pytest
  from mlflow.store.artifact.artifact_repository_registry import get_artifact_repository
  from mlflow.store.artifact.s3_artifact_repo import _cached_get_s3_client
  from tests.helper_functions import set_boto_credentials
label_desc: Use image node_id 7 for calling a global function with example usage: test_get_r2_client_region_name_set_correctly(r2_artifact_root) without return types