code: def test_registry_instance_loads_entrypoints():
      class MockRequestHeaderProvider:
          pass
  
      mock_entrypoint = mock.Mock()
      mock_entrypoint.load.return_value = MockRequestHeaderProvider
  
      with mock.patch(
          "entrypoints.get_group_all", return_value=[mock_entrypoint]
      ) as mock_get_group_all:
          # Entrypoints are registered at import time, so we need to reload the module to register the
          # entrypoint given by the mocked entrypoints.get_group_all
          reload(mlflow.tracking.request_header.registry)
  
      assert (
          MockRequestHeaderProvider
          in _currently_registered_request_header_provider_classes()
      )
      mock_get_group_all.assert_called_once_with(
          "mlflow.request_header_provider"
      )
  
file_path: mlflow/tests/tracking/request_header/test_registry.py
imports: from importlib import reload
  from unittest import mock
  import pytest
  import mlflow.tracking.request_header.registry
  from mlflow.tracking.request_header.databricks_request_header_provider import DatabricksRequestHeaderProvider
  from mlflow.tracking.request_header.registry import RequestHeaderProviderRegistry, resolve_request_headers
label_desc: Use image node_id 7 for calling a global function with example usage: test_registry_instance_loads_entrypoints() without return types