diff --git a/CHANGELOG.md b/CHANGELOG.md index acebeb87..d5231e87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/lang/zh-CN/ - 修复重新测试时没有提示测试进行中的问题 - 修复机器人修改议题等操作时仍会触发响应器的问题 +- 修复修改配置流程中忘记修改标题的问题 ## [4.1.1] - 2024-12-01 diff --git a/src/plugins/github/plugins/config/__init__.py b/src/plugins/github/plugins/config/__init__.py index 52400621..59521c19 100644 --- a/src/plugins/github/plugins/config/__init__.py +++ b/src/plugins/github/plugins/config/__init__.py @@ -96,6 +96,9 @@ async def handle_remove_check( # 限制标题长度,过长的标题不好看 title = f"{result.type}: {result.name[:TITLE_MAX_LENGTH]}" + # 修改议题标题 + await handler.update_issue_title(title) + if result.valid: commit_message = f"{COMMIT_MESSAGE_PREFIX} {result.type.value.lower()} {result.name} (#{handler.issue_number})" diff --git a/tests/github/config/process/test_config_check.py b/tests/github/config/process/test_config_check.py index ee86bafa..46e6e077 100644 --- a/tests/github/config/process/test_config_check.py +++ b/tests/github/config/process/test_config_check.py @@ -165,6 +165,18 @@ async def test_process_config_check( }, True, ) + ctx.should_call_api( + "rest.issues.async_update", + snapshot( + { + "owner": "he0119", + "repo": "action-test", + "issue_number": 80, + "title": "Plugin: name", + } + ), + None, + ) ctx.should_call_api( "rest.pulls.async_create", snapshot(