mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-10-08 19:56:45 +00:00
✨ Feature: 更新 NB-CLI 新版插件加载格式与文档 (#3614)
This commit is contained in:
3
tests/plugins.legacy.toml
Normal file
3
tests/plugins.legacy.toml
Normal file
@@ -0,0 +1,3 @@
|
||||
[tool.nonebot]
|
||||
plugins = []
|
||||
plugin_dirs = []
|
@@ -1,3 +1,5 @@
|
||||
[tool.nonebot]
|
||||
plugins = []
|
||||
plugin_dirs = []
|
||||
|
||||
[tool.nonebot.plugins]
|
||||
"@local" = []
|
||||
|
@@ -93,6 +93,8 @@ def test_load_json():
|
||||
|
||||
@_recover
|
||||
def test_load_toml():
|
||||
nonebot.load_from_toml("./plugins.legacy.toml")
|
||||
|
||||
nonebot.load_from_toml("./plugins.toml")
|
||||
|
||||
with pytest.raises(ValueError, match="Cannot find"):
|
||||
|
Reference in New Issue
Block a user