feat: 添加测试覆盖率并修复相关问题
refactor(redis_manager): 移除冗余的ConnectionError处理 refactor(event_handler): 优化Bot类型注解 refactor(factory): 移除未使用的GroupCardNoticeEvent test: 添加全面的单元测试覆盖 - 添加test_import.py测试模块导入 - 添加test_debug.py测试插件加载调试 - 添加test_plugin_error.py测试错误处理 - 添加test_config_loader.py测试配置加载 - 添加test_redis_manager.py测试Redis管理 - 添加test_bot.py测试Bot功能 - 扩展test_models.py测试消息模型 - 添加test_plugin_manager_coverage.py测试插件管理 - 添加test_executor.py测试代码执行器 - 添加test_ws.py测试WebSocket - 添加test_api.py测试API接口 - 添加test_core_managers.py测试核心管理模块 fix(plugin_manager): 修复插件加载日志变量问题 覆盖率已到达86%(忽略插件)
This commit is contained in:
@@ -256,15 +256,6 @@ class EventFactory:
|
||||
card_new=data.get("card_new", ""),
|
||||
card_old=data.get("card_old", "")
|
||||
)
|
||||
elif notice_type == "group_card":
|
||||
return GroupCardNoticeEvent(
|
||||
**common_args,
|
||||
notice_type=notice_type,
|
||||
group_id=data.get("group_id", 0),
|
||||
user_id=data.get("user_id", 0),
|
||||
card_new=data.get("card_new", ""),
|
||||
card_old=data.get("card_old", "")
|
||||
)
|
||||
elif notice_type == "offline_file":
|
||||
file_data = data.get("file", {})
|
||||
offline_file = OfflineFile(
|
||||
|
||||
Reference in New Issue
Block a user