stable

Clone or download

Read-only

Smarter A.I. for commenter bot

Create a Merge Request in gitlab that references one ore more artifacts (tuleap-xxxx). => a comment is added to the Merge Request and list all valid references. Edit the Merge Request and add some references. => a comment is added and list all current valid references. Edit the Merge Request, change the title or description without changing the references. => no comment is added Approve the Merge Request => no comment is added Edit the Merge Request and remove some references. => a comment is added and list all current valid references. Edit the Merge Request and remove all references. => no comment is added Note: initial thought was to use cross_references table to know if MR will add/remove references. However since we never clean this table (previous references are kept) we cannot rely on that. Instead we use the previous title/description of the MR that has been saved earlier. Part of story #17182: reference tuleap artifacts in gitlab merge requests Change-Id: I88b745b73345621b007ae479331035caaa1d9f4b

Modified Files

Name
M plugins/gitlab/include/Repository/Webhook/PostMergeRequest/MergeRequestTuleapReferenceDao.php +2 −2 Go to diff View file
M plugins/gitlab/include/Repository/Webhook/PostMergeRequest/PostMergeRequestWebhookActionProcessor.php +138 −47 Go to diff View file
M plugins/gitlab/include/Repository/Webhook/WebhookTuleapReference.php +5 −0 Go to diff View file
M plugins/gitlab/tests/unit/Repository/Webhook/PostMergeRequest/PostMergeRequestWebhookActionProcessorTest.php +322 −8 Go to diff View file
A plugins/gitlab/tests/unit/Repository/Webhook/WebhookTuleapReferenceTest.php +38 −0 Go to diff View file