code: def test_enable_local_plugin_from_config(local_config):
      """App can load a local plugin from config file."""
      cfg, cfg_dir = config.load_config(
          local_config, [], isolated=False
      )
      opts = finder.parse_plugin_options(
          cfg,
          cfg_dir,
          enable_extensions=None,
          require_plugins=None,
      )
      plugins = finder.find_plugins(cfg, opts)
      loaded_plugins = finder.load_plugins(plugins, opts)
  
      (custom_extension,) = (
          loaded
          for loaded in loaded_plugins.checkers.tree
          if loaded.entry_name == "XE"
      )
      custom_report = loaded_plugins.reporters["XR"]
  
      assert custom_extension.obj is ExtensionTestPlugin
      assert custom_report.obj is ReportTestPlugin
  
imports: from __future__ import annotations
  import pytest
  from flake8.main.cli import main
  from flake8.main.options import register_default_options
  from flake8.main.options import stage1_arg_parser
  from flake8.options import aggregator
  from flake8.options import config
  from flake8.options.manager import OptionManager
  from flake8.plugins import finder
label_desc: Use image node_id 2 for calling a global function with example usage: test_enable_local_plugin_from_config(local_config) without return types