code: def test_download_artifact_throws_value_error_when_listed_blobs_do_not_contain_artifact_root_prefix(
      mock_client,
  ):
      repo = AzureBlobArtifactRepository(TEST_URI, mock_client)
  
      # Create a "bad blob" with a name that is not prefixed by the root path of the artifact store
      bad_blob_props = BlobProperties()
      bad_blob_props.size = 42
      bad_blob_props.name = "file_path"
  
      def get_mock_listing(*args, **kwargs):
          """
          Produces a mock listing that only contains content if the
          specified prefix is the artifact root. This allows us to mock
          `list_artifacts` during the `_download_artifacts_into` subroutine
          without recursively listing the same artifacts at every level of the
          directory traversal.
          """
          # pylint: disable=unused-argument
          if posixpath.abspath(
              kwargs["name_starts_with"]
          ) == posixpath.abspath(TEST_ROOT_PATH):
              # Return a blob that is not prefixed by the root path of the artifact store. This
              # should result in an exception being raised
              return MockBlobList([bad_blob_props])
          else:
              return MockBlobList([])
  
      mock_client.get_container_client().walk_blobs.side_effect = (
          get_mock_listing
      )
  
      with pytest.raises(
          MlflowException,
          match="Azure blob does not begin with the specified artifact path",
      ):
          repo.download_artifacts("")
  
imports: import base64
  import os
  import posixpath
  from unittest import mock
  import pytest
  from azure.storage.blob import BlobPrefix, BlobProperties, BlobServiceClient
  from mlflow.entities.multipart_upload import MultipartUploadPart
  from mlflow.exceptions import MlflowException
  from mlflow.store.artifact.artifact_repository_registry import get_artifact_repository
  from mlflow.store.artifact.azure_blob_artifact_repo import AzureBlobArtifactRepository
label_desc: Use image node_id 14 for calling a global function with example usage: test_download_artifact_throws_value_error_when_listed_blobs_do_not_contain_artifact_root_prefix(mock_client) and returns: MockBlobList, MockBlobList