Skip to content

Commit

Permalink
Merge branch 'nonebot:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
BigOrangeQWQ authored Nov 8, 2024
2 parents 375e3c8 + 6804189 commit 754bea3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/providers/validation/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ def plugin_test_load_validator(cls, v: bool, info: ValidationInfo) -> bool:
raise PydanticCustomError(
"plugin.test",
"插件无法正常加载",
{"output": context.get("plugin_test_output")},
{"output": context.get("test_output")},
)

@field_validator("metadata", mode="before")
Expand Down
7 changes: 6 additions & 1 deletion tests/utils/store_test/test_validate_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,12 @@ async def test_validate_plugin_failed_with_previous(
"loc": ("load",),
"msg": "插件无法正常加载",
"input": False,
"ctx": {"output": None},
"ctx": {
"output": """\
创建测试目录 plugin_test
For further information visit https://errors.pydantic.dev/2.9/v/model_type\x1b[0m\
"""
},
},
],
},
Expand Down
2 changes: 1 addition & 1 deletion tests/utils/validation/test_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ async def test_plugin_info_validation_plugin_load_failed(
"loc": ("load",),
"msg": "插件无法正常加载",
"input": False,
"ctx": {"output": None},
"ctx": {"output": "test_output"},
}
],
info=None,
Expand Down

0 comments on commit 754bea3

Please sign in to comment.