Fix staticcheck errors from _test.go files (#18033)

Automatic Merge
Этот коммит содержится в:
dave
2021-08-10 13:15:03 +08:00
коммит произвёл GitHub
родитель 3f01129ddf
Коммит 16c2925ba2
28 изменённых файлов: 70 добавлений и 88 удалений

Просмотреть файл

@@ -130,7 +130,7 @@ func TestCreateIncomingWebhook_BypassTeamPermissions(t *testing.T) {
channel := th.CreateChannelWithClientAndTeam(th.SystemAdminClient, model.ChannelTypeOpen, team.Id)
hook = &model.IncomingWebhook{ChannelId: channel.Id}
rhook, resp = th.Client.CreateIncomingWebhook(hook)
_, resp = th.Client.CreateIncomingWebhook(hook)
CheckForbiddenStatus(t, resp)
}
@@ -915,7 +915,7 @@ func TestUpdateIncomingWebhook_BypassTeamPermissions(t *testing.T) {
channel := th.CreateChannelWithClientAndTeam(th.SystemAdminClient, model.ChannelTypeOpen, team.Id)
hook2 := &model.IncomingWebhook{Id: rhook.Id, ChannelId: channel.Id}
rhook, resp = th.Client.UpdateIncomingWebhook(hook2)
_, resp = th.Client.UpdateIncomingWebhook(hook2)
CheckBadRequestStatus(t, resp)
}
@@ -1171,7 +1171,7 @@ func TestUpdateOutgoingWebhook_BypassTeamPermissions(t *testing.T) {
channel := th.CreateChannelWithClientAndTeam(th.SystemAdminClient, model.ChannelTypeOpen, team.Id)
hook2 := &model.OutgoingWebhook{Id: rhook.Id, ChannelId: channel.Id}
rhook, resp = th.Client.UpdateOutgoingWebhook(hook2)
_, resp = th.Client.UpdateOutgoingWebhook(hook2)
CheckForbiddenStatus(t, resp)
}