Complete push webhooks (#2530)
* implemented missing 'delete' push webhooks moreover created ActionDeleteBranch and ActionDeleteTag * add CommitRepoAction tests for tag/branch creation/deletion * fixed error where push webhook not called if is new branch or tag removed unnecessary code * moved prepare unit test environment into separate method to be used across unit tests * add missing if clause in pushUpdate Signed-off-by: David Schneiderbauer <dschneiderbauer@gmail.com>
This commit is contained in:
parent
0d80af649a
commit
1eedd983ea
8 changed files with 221 additions and 126 deletions
|
@ -294,7 +294,7 @@ func ActionIcon(opType models.ActionType) string {
|
|||
switch opType {
|
||||
case models.ActionCreateRepo, models.ActionTransferRepo:
|
||||
return "repo"
|
||||
case models.ActionCommitRepo, models.ActionPushTag:
|
||||
case models.ActionCommitRepo, models.ActionPushTag, models.ActionDeleteTag, models.ActionDeleteBranch:
|
||||
return "git-commit"
|
||||
case models.ActionCreateIssue:
|
||||
return "issue-opened"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue