Add tests for webhook and fix some webhook bugs (#33396)

This PR created a mock webhook server in the tests and added integration
tests for generic webhooks.
It also fixes bugs in package webhooks and pull request comment
webhooks.
This commit is contained in:
Lunny Xiao authored and GitHub committed 2025-01-30 03:09:48 +00:00
1 parent 256b94e9e9
commit 75940a0191
22 files changed
+630 -89

No files matched your search

+4
View File
@@ -190,3 +190,7 @@ func newDingtalkRequest(_ context.Context, w *webhook_model.Webhook, t *webhook_
var pc payloadConvertor[DingtalkPayload] = dingtalkConvertor{}
return newJSONRequest(pc, w, t, true)
}
func init() {
RegisterWebhookRequester(webhook_module.DINGTALK, newDingtalkRequest)
}