code: def test_log_artifacts(local_artifact_repo, local_artifact_root):
      artifact_rel_path = "test.txt"
      artifact_text = "hello world!"
      with TempDir() as src_dir:
          artifact_src_path = src_dir.path(artifact_rel_path)
          with open(artifact_src_path, "w") as f:
              f.write(artifact_text)
          local_artifact_repo.log_artifact(artifact_src_path)
  
      artifacts_list = local_artifact_repo.list_artifacts()
      assert len(artifacts_list) == 1
      assert artifacts_list[0].path == artifact_rel_path
  
      artifact_dst_path = os.path.join(
          local_artifact_root, artifact_rel_path
      )
      assert os.path.exists(artifact_dst_path)
      assert artifact_dst_path != artifact_src_path
      with open(artifact_dst_path) as f:
          assert f.read() == artifact_text
  
file_path: mlflow/tests/store/artifact/test_local_artifact_repo.py
imports: import os
  import posixpath
  import pytest
  from mlflow.exceptions import MlflowException
  from mlflow.store.artifact.local_artifact_repo import LocalArtifactRepository
  from mlflow.utils.file_utils import TempDir
label_desc: Use image node_id 4 for calling a global function with example usage: test_log_artifacts(local_artifact_repo, local_artifact_root) without return types