code: def testMlFlowLoggerCallbackConfig(self):
      # Explicitly pass in all args.
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri,
          registry_uri=self.registry_uri,
          experiment_name="test_exp",
      )
      logger.setup()
      self.assertEqual(
          logger.mlflow_util._mlflow.get_tracking_uri(),
          self.tracking_uri,
      )
      self.assertEqual(
          logger.mlflow_util._mlflow.get_registry_uri(),
          self.registry_uri,
      )
      self.assertListEqual(
          [
              e.name
              for e in logger.mlflow_util._mlflow.search_experiments()
          ],
          ["test_exp", "existing_experiment", "Default"],
      )
      self.assertEqual(logger.mlflow_util.experiment_id, "2")
  
      # Check if client recognizes already existing experiment.
      logger = MLflowLoggerCallback(
          experiment_name="existing_experiment",
          tracking_uri=self.tracking_uri,
          registry_uri=self.registry_uri,
      )
      logger.setup()
      self.assertEqual(logger.mlflow_util.experiment_id, "1")
  
      # Pass in experiment name as env var.
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_NAME"] = "test_exp"
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri, registry_uri=self.registry_uri
      )
      logger.setup()
      self.assertEqual(logger.mlflow_util.experiment_id, "2")
  
      # Pass in existing experiment name as env var.
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_NAME"] = "existing_experiment"
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri, registry_uri=self.registry_uri
      )
      logger.setup()
      self.assertEqual(logger.mlflow_util.experiment_id, "1")
  
      # Pass in existing experiment id as env var.
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_ID"] = "1"
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri, registry_uri=self.registry_uri
      )
      logger.setup()
      self.assertEqual(logger.mlflow_util.experiment_id, "1")
  
      # Pass in non existing experiment id as env var.
      # This should create a new experiment.
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_ID"] = "500"
      with self.assertRaises(ValueError):
          logger = MLflowLoggerCallback(
              tracking_uri=self.tracking_uri,
              registry_uri=self.registry_uri,
          )
          logger.setup()
  
      # Experiment id env var should take precedence over name env var.
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_NAME"] = "test_exp"
      os.environ["MLFLOW_EXPERIMENT_ID"] = "1"
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri, registry_uri=self.registry_uri
      )
      logger.setup()
      self.assertEqual(logger.mlflow_util.experiment_id, "1")
  
      # Using tags
      tags = {"user_name": "John", "git_commit_hash": "abc123"}
      clear_env_vars()
      os.environ["MLFLOW_EXPERIMENT_NAME"] = "test_tags"
      os.environ["MLFLOW_EXPERIMENT_ID"] = "1"
      logger = MLflowLoggerCallback(
          tracking_uri=self.tracking_uri,
          registry_uri=self.registry_uri,
          tags=tags,
      )
      logger.setup()
      self.assertEqual(logger.tags, tags)
  
imports: import os
  import shutil
  import tempfile
  import unittest
  from collections import namedtuple
  from unittest.mock import patch
  from mlflow.tracking import MlflowClient
  from ray._private.dict import flatten_dict
  from ray.train._internal.session import init_session, shutdown_session
  from ray.train._internal.storage import StorageContext
  from ray.air.integrations.mlflow import MLflowLoggerCallback, setup_mlflow, _NoopModule
  from ray.air._internal.mlflow import _MLflowLoggerUtil
label_desc: Use image node_id 3 for calling the MLflowTest obj's underlying member method code with example usage: obj.testMlFlowLoggerCallbackConfig() without return types