mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-07-17 11:31:18 +00:00
⚡ improve plugin system (#1011)
This commit is contained in:
12
tests/test_plugin/test_manager.py
Normal file
12
tests/test_plugin/test_manager.py
Normal file
@ -0,0 +1,12 @@
|
||||
import pytest
|
||||
from nonebug import App
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_load_plugin_name(app: App):
|
||||
from nonebot.plugin import PluginManager
|
||||
|
||||
m = PluginManager(plugins=["plugins.export"])
|
||||
module1 = m.load_plugin("export")
|
||||
module2 = m.load_plugin("plugins.export")
|
||||
assert module1 is module2
|
Reference in New Issue
Block a user