add weibo test

This commit is contained in:
felinae98 2021-06-17 13:02:28 +08:00
parent 17bf73bc34
commit b3e305cbbb
No known key found for this signature in database
GPG Key ID: 00C8B010587FF610

View File

@ -0,0 +1,12 @@
import pytest
import typing
if typing.TYPE_CHECKING:
import sys
sys.path.append('./src/plugins')
import nonebot_hk_reporter
@pytest.mark.asyncio
async def test_get_name(plugin_module: 'nonebot_hk_reporter'):
weibo = plugin_module.platform.platform_manager['weibo']
name = await weibo.get_account_name('6279793937')
assert(name == "明日方舟Arknights")