code: def mock_run_context_providers():
      base_provider = mock.Mock()
      base_provider.in_context.return_value = True
      base_provider.tags.return_value = {
          "one": "one-val",
          "two": "two-val",
          "three": "three-val",
      }
  
      skipped_provider = mock.Mock()
      skipped_provider.in_context.return_value = False
  
      exception_provider = mock.Mock()
      exception_provider.in_context.return_value = True
      exception_provider.tags.return_value = {
          "random-key": "This val will never make it to tag resolution"
      }
      exception_provider.tags.side_effect = Exception(
          "This should be caught by logic in resolve_tags()"
      )
  
      override_provider = mock.Mock()
      override_provider.in_context.return_value = True
      override_provider.tags.return_value = {
          "one": "override",
          "new": "new-val",
      }
  
      providers = [
          base_provider,
          skipped_provider,
          exception_provider,
          override_provider,
      ]
  
      with mock.patch(
          "mlflow.tracking.context.registry._run_context_provider_registry",
          providers,
      ):
          yield
  
      skipped_provider.tags.assert_not_called()
  
file_path: mlflow/tests/tracking/context/test_registry.py
imports: from importlib import reload
  from unittest import mock
  import pytest
  import mlflow.tracking.context.registry
  from mlflow.tracking.context.databricks_job_context import DatabricksJobRunContext
  from mlflow.tracking.context.databricks_notebook_context import DatabricksNotebookRunContext
  from mlflow.tracking.context.databricks_repo_context import DatabricksRepoRunContext
  from mlflow.tracking.context.default_context import DefaultRunContext
  from mlflow.tracking.context.git_context import GitRunContext
  from mlflow.tracking.context.registry import RunContextProviderRegistry, resolve_tags
label_desc: Use image node_id 8 for calling a global function with example usage: mock_run_context_providers() without return types