code: def test_download_artifact_from_absolute_uri_persists_data_to_specified_output_directory(
      tmp_path,
  ):
      artifact_file_name = "artifact.txt"
      artifact_text = "Sample artifact text"
      local_artifact_path = tmp_path.joinpath(artifact_file_name)
      local_artifact_path.write_text(artifact_text)
  
      logged_artifact_subdir = "logged_artifact"
      with mlflow.start_run():
          mlflow.log_artifact(
              local_path=local_artifact_path,
              artifact_path=logged_artifact_subdir,
          )
          artifact_uri = mlflow.get_artifact_uri(
              artifact_path=logged_artifact_subdir
          )
  
      artifact_output_path = tmp_path.joinpath("artifact_output")
      artifact_output_path.mkdir()
      _download_artifact_from_uri(
          artifact_uri=artifact_uri, output_path=artifact_output_path
      )
      assert logged_artifact_subdir in os.listdir(artifact_output_path)
      assert artifact_file_name in os.listdir(
          os.path.join(artifact_output_path, logged_artifact_subdir)
      )
      with open(
          os.path.join(
              artifact_output_path,
              logged_artifact_subdir,
              artifact_file_name,
          )
      ) as f:
          assert f.read() == artifact_text
  
file_path: mlflow/tests/tracking/test_artifact_utils.py
imports: import os
  from unittest import mock
  from unittest.mock import ANY
  from uuid import UUID
  import mlflow
  from mlflow.tracking.artifact_utils import _download_artifact_from_uri, _upload_artifact_to_uri, _upload_artifacts_to_databricks
label_desc: Use image node_id 2 for calling a global function with example usage: test_download_artifact_from_absolute_uri_persists_data_to_specified_output_directory(tmp_path) without return types