code: def test_import_dashboard_managed_externally(
      mocker: MockFixture,
      session: Session,
  ) -> None:
      """
      Test importing a dashboard that is managed externally.
      """
      from superset import security_manager
      from superset.commands.dashboard.importers.v1.utils import (
          import_dashboard,
      )
      from superset.connectors.sqla.models import SqlaTable
      from superset.models.core import Database
      from superset.models.slice import Slice
      from tests.integration_tests.fixtures.importexport import (
          dashboard_config,
      )
  
      mocker.patch.object(
          security_manager, "can_access", return_value=True
      )
  
      engine = session.get_bind()
      Slice.metadata.create_all(engine)  # pylint: disable=no-member
  
      config = copy.deepcopy(dashboard_config)
      config["is_managed_externally"] = True
      config["external_url"] = "https://example.org/my_dashboard"
  
      dashboard = import_dashboard(session, config)
      assert dashboard.is_managed_externally is True
      assert (
          dashboard.external_url == "https://example.org/my_dashboard"
      )
  
file_path: superset/tests/unit_tests/dashboards/commands/importers/v1/import_test.py
imports: import copy
  import pytest
  from pytest_mock import MockFixture
  from sqlalchemy.orm.session import Session
  from superset.commands.exceptions import ImportFailedError
label_desc: Use image node_id 2 for calling a global function with example usage: test_import_dashboard_managed_externally(mocker, session) without return types