code: def test_register_plugin() -> None:
      class MyPlugin(SearchPathPlugin):
          def manipulate_search_path(
              self, search_path: ConfigSearchPath
          ) -> None:
              ...
  
      Plugins.instance().register(MyPlugin)
  
      assert MyPlugin in Plugins.instance().discover(Plugin)
      assert MyPlugin in Plugins.instance().discover(SearchPathPlugin)
      assert MyPlugin not in Plugins.instance().discover(Launcher)
  
file_path: hydra/tests/test_plugin_interface.py
imports: from typing import List, Type
  from pytest import mark, raises
  from hydra.core.config_search_path import ConfigSearchPath
  from hydra.core.plugins import Plugins
  from hydra.plugins.launcher import Launcher
  from hydra.plugins.plugin import Plugin
  from hydra.plugins.search_path_plugin import SearchPathPlugin
  from hydra.plugins.sweeper import Sweeper
  from hydra.utils import get_class
label_desc: Use image node_id 2 for calling a global function with example usage: test_register_plugin() without return types