mirror of
https://github.com/nonebot/nonebot2.git
synced 2024-12-18 17:35:46 +08:00
15 lines
372 B
Python
15 lines
372 B
Python
import pytest
|
|
from nonebug import App
|
|
|
|
from nonebot.matcher import DEFAULT_PROVIDER_CLASS, matchers
|
|
|
|
|
|
@pytest.mark.asyncio
|
|
async def test_manager(app: App):
|
|
try:
|
|
default_provider = matchers.provider
|
|
matchers.set_provider(DEFAULT_PROVIDER_CLASS)
|
|
assert default_provider == matchers.provider
|
|
finally:
|
|
matchers.provider = app.provider
|