mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-09-06 20:16:47 +00:00
✅ add param tests
This commit is contained in:
14
tests/plugins/param/param_arg.py
Normal file
14
tests/plugins/param/param_arg.py
Normal file
@ -0,0 +1,14 @@
|
||||
from nonebot.adapters import Event, Message
|
||||
from nonebot.params import Arg, ArgStr, ArgEvent
|
||||
|
||||
|
||||
async def arg(key: Message = Arg()) -> Message:
|
||||
return key
|
||||
|
||||
|
||||
async def arg_str(key: str = ArgStr()) -> str:
|
||||
return key
|
||||
|
||||
|
||||
async def arg_event(key: Event = ArgEvent()) -> Event:
|
||||
return key
|
Reference in New Issue
Block a user