WebhookStore migration (#15042)
* Migration completed * Fix tests Co-authored-by: Jesús Espino <jespinog@gmail.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
ed3c93716d
Коммит
1c5b6522e3
@@ -15,7 +15,7 @@ type WebhookStore struct {
|
||||
}
|
||||
|
||||
// AnalyticsIncomingCount provides a mock function with given fields: teamId
|
||||
func (_m *WebhookStore) AnalyticsIncomingCount(teamId string) (int64, *model.AppError) {
|
||||
func (_m *WebhookStore) AnalyticsIncomingCount(teamId string) (int64, error) {
|
||||
ret := _m.Called(teamId)
|
||||
|
||||
var r0 int64
|
||||
@@ -25,20 +25,18 @@ func (_m *WebhookStore) AnalyticsIncomingCount(teamId string) (int64, *model.App
|
||||
r0 = ret.Get(0).(int64)
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string) error); ok {
|
||||
r1 = rf(teamId)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// AnalyticsOutgoingCount provides a mock function with given fields: teamId
|
||||
func (_m *WebhookStore) AnalyticsOutgoingCount(teamId string) (int64, *model.AppError) {
|
||||
func (_m *WebhookStore) AnalyticsOutgoingCount(teamId string) (int64, error) {
|
||||
ret := _m.Called(teamId)
|
||||
|
||||
var r0 int64
|
||||
@@ -48,13 +46,11 @@ func (_m *WebhookStore) AnalyticsOutgoingCount(teamId string) (int64, *model.App
|
||||
r0 = ret.Get(0).(int64)
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string) error); ok {
|
||||
r1 = rf(teamId)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
@@ -66,39 +62,35 @@ func (_m *WebhookStore) ClearCaches() {
|
||||
}
|
||||
|
||||
// DeleteIncoming provides a mock function with given fields: webhookId, time
|
||||
func (_m *WebhookStore) DeleteIncoming(webhookId string, time int64) *model.AppError {
|
||||
func (_m *WebhookStore) DeleteIncoming(webhookId string, time int64) error {
|
||||
ret := _m.Called(webhookId, time)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string, int64) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string, int64) error); ok {
|
||||
r0 = rf(webhookId, time)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// DeleteOutgoing provides a mock function with given fields: webhookId, time
|
||||
func (_m *WebhookStore) DeleteOutgoing(webhookId string, time int64) *model.AppError {
|
||||
func (_m *WebhookStore) DeleteOutgoing(webhookId string, time int64) error {
|
||||
ret := _m.Called(webhookId, time)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string, int64) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string, int64) error); ok {
|
||||
r0 = rf(webhookId, time)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// GetIncoming provides a mock function with given fields: id, allowFromCache
|
||||
func (_m *WebhookStore) GetIncoming(id string, allowFromCache bool) (*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncoming(id string, allowFromCache bool) (*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(id, allowFromCache)
|
||||
|
||||
var r0 *model.IncomingWebhook
|
||||
@@ -110,20 +102,18 @@ func (_m *WebhookStore) GetIncoming(id string, allowFromCache bool) (*model.Inco
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, bool) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, bool) error); ok {
|
||||
r1 = rf(id, allowFromCache)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetIncomingByChannel provides a mock function with given fields: channelId
|
||||
func (_m *WebhookStore) GetIncomingByChannel(channelId string) ([]*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncomingByChannel(channelId string) ([]*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(channelId)
|
||||
|
||||
var r0 []*model.IncomingWebhook
|
||||
@@ -135,20 +125,18 @@ func (_m *WebhookStore) GetIncomingByChannel(channelId string) ([]*model.Incomin
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string) error); ok {
|
||||
r1 = rf(channelId)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetIncomingByTeam provides a mock function with given fields: teamId, offset, limit
|
||||
func (_m *WebhookStore) GetIncomingByTeam(teamId string, offset int, limit int) ([]*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncomingByTeam(teamId string, offset int, limit int) ([]*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(teamId, offset, limit)
|
||||
|
||||
var r0 []*model.IncomingWebhook
|
||||
@@ -160,20 +148,18 @@ func (_m *WebhookStore) GetIncomingByTeam(teamId string, offset int, limit int)
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) error); ok {
|
||||
r1 = rf(teamId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetIncomingByTeamByUser provides a mock function with given fields: teamId, userId, offset, limit
|
||||
func (_m *WebhookStore) GetIncomingByTeamByUser(teamId string, userId string, offset int, limit int) ([]*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncomingByTeamByUser(teamId string, userId string, offset int, limit int) ([]*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(teamId, userId, offset, limit)
|
||||
|
||||
var r0 []*model.IncomingWebhook
|
||||
@@ -185,20 +171,18 @@ func (_m *WebhookStore) GetIncomingByTeamByUser(teamId string, userId string, of
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) error); ok {
|
||||
r1 = rf(teamId, userId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetIncomingList provides a mock function with given fields: offset, limit
|
||||
func (_m *WebhookStore) GetIncomingList(offset int, limit int) ([]*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncomingList(offset int, limit int) ([]*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(offset, limit)
|
||||
|
||||
var r0 []*model.IncomingWebhook
|
||||
@@ -210,20 +194,18 @@ func (_m *WebhookStore) GetIncomingList(offset int, limit int) ([]*model.Incomin
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(int, int) error); ok {
|
||||
r1 = rf(offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetIncomingListByUser provides a mock function with given fields: userId, offset, limit
|
||||
func (_m *WebhookStore) GetIncomingListByUser(userId string, offset int, limit int) ([]*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetIncomingListByUser(userId string, offset int, limit int) ([]*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(userId, offset, limit)
|
||||
|
||||
var r0 []*model.IncomingWebhook
|
||||
@@ -235,20 +217,18 @@ func (_m *WebhookStore) GetIncomingListByUser(userId string, offset int, limit i
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) error); ok {
|
||||
r1 = rf(userId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoing provides a mock function with given fields: id
|
||||
func (_m *WebhookStore) GetOutgoing(id string) (*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoing(id string) (*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(id)
|
||||
|
||||
var r0 *model.OutgoingWebhook
|
||||
@@ -260,20 +240,18 @@ func (_m *WebhookStore) GetOutgoing(id string) (*model.OutgoingWebhook, *model.A
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string) error); ok {
|
||||
r1 = rf(id)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingByChannel provides a mock function with given fields: channelId, offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingByChannel(channelId string, offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingByChannel(channelId string, offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(channelId, offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -285,20 +263,18 @@ func (_m *WebhookStore) GetOutgoingByChannel(channelId string, offset int, limit
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) error); ok {
|
||||
r1 = rf(channelId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingByChannelByUser provides a mock function with given fields: channelId, userId, offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingByChannelByUser(channelId string, userId string, offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingByChannelByUser(channelId string, userId string, offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(channelId, userId, offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -310,20 +286,18 @@ func (_m *WebhookStore) GetOutgoingByChannelByUser(channelId string, userId stri
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) error); ok {
|
||||
r1 = rf(channelId, userId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingByTeam provides a mock function with given fields: teamId, offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingByTeam(teamId string, offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingByTeam(teamId string, offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(teamId, offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -335,20 +309,18 @@ func (_m *WebhookStore) GetOutgoingByTeam(teamId string, offset int, limit int)
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) error); ok {
|
||||
r1 = rf(teamId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingByTeamByUser provides a mock function with given fields: teamId, userId, offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingByTeamByUser(teamId string, userId string, offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingByTeamByUser(teamId string, userId string, offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(teamId, userId, offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -360,20 +332,18 @@ func (_m *WebhookStore) GetOutgoingByTeamByUser(teamId string, userId string, of
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, string, int, int) error); ok {
|
||||
r1 = rf(teamId, userId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingList provides a mock function with given fields: offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingList(offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingList(offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -385,20 +355,18 @@ func (_m *WebhookStore) GetOutgoingList(offset int, limit int) ([]*model.Outgoin
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(int, int) error); ok {
|
||||
r1 = rf(offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// GetOutgoingListByUser provides a mock function with given fields: userId, offset, limit
|
||||
func (_m *WebhookStore) GetOutgoingListByUser(userId string, offset int, limit int) ([]*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) GetOutgoingListByUser(userId string, offset int, limit int) ([]*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(userId, offset, limit)
|
||||
|
||||
var r0 []*model.OutgoingWebhook
|
||||
@@ -410,13 +378,11 @@ func (_m *WebhookStore) GetOutgoingListByUser(userId string, offset int, limit i
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(string, int, int) error); ok {
|
||||
r1 = rf(userId, offset, limit)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
@@ -428,71 +394,63 @@ func (_m *WebhookStore) InvalidateWebhookCache(webhook string) {
|
||||
}
|
||||
|
||||
// PermanentDeleteIncomingByChannel provides a mock function with given fields: channelId
|
||||
func (_m *WebhookStore) PermanentDeleteIncomingByChannel(channelId string) *model.AppError {
|
||||
func (_m *WebhookStore) PermanentDeleteIncomingByChannel(channelId string) error {
|
||||
ret := _m.Called(channelId)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string) error); ok {
|
||||
r0 = rf(channelId)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// PermanentDeleteIncomingByUser provides a mock function with given fields: userId
|
||||
func (_m *WebhookStore) PermanentDeleteIncomingByUser(userId string) *model.AppError {
|
||||
func (_m *WebhookStore) PermanentDeleteIncomingByUser(userId string) error {
|
||||
ret := _m.Called(userId)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string) error); ok {
|
||||
r0 = rf(userId)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// PermanentDeleteOutgoingByChannel provides a mock function with given fields: channelId
|
||||
func (_m *WebhookStore) PermanentDeleteOutgoingByChannel(channelId string) *model.AppError {
|
||||
func (_m *WebhookStore) PermanentDeleteOutgoingByChannel(channelId string) error {
|
||||
ret := _m.Called(channelId)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string) error); ok {
|
||||
r0 = rf(channelId)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// PermanentDeleteOutgoingByUser provides a mock function with given fields: userId
|
||||
func (_m *WebhookStore) PermanentDeleteOutgoingByUser(userId string) *model.AppError {
|
||||
func (_m *WebhookStore) PermanentDeleteOutgoingByUser(userId string) error {
|
||||
ret := _m.Called(userId)
|
||||
|
||||
var r0 *model.AppError
|
||||
if rf, ok := ret.Get(0).(func(string) *model.AppError); ok {
|
||||
var r0 error
|
||||
if rf, ok := ret.Get(0).(func(string) error); ok {
|
||||
r0 = rf(userId)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*model.AppError)
|
||||
}
|
||||
r0 = ret.Error(0)
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// SaveIncoming provides a mock function with given fields: webhook
|
||||
func (_m *WebhookStore) SaveIncoming(webhook *model.IncomingWebhook) (*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) SaveIncoming(webhook *model.IncomingWebhook) (*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(webhook)
|
||||
|
||||
var r0 *model.IncomingWebhook
|
||||
@@ -504,20 +462,18 @@ func (_m *WebhookStore) SaveIncoming(webhook *model.IncomingWebhook) (*model.Inc
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(*model.IncomingWebhook) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(*model.IncomingWebhook) error); ok {
|
||||
r1 = rf(webhook)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// SaveOutgoing provides a mock function with given fields: webhook
|
||||
func (_m *WebhookStore) SaveOutgoing(webhook *model.OutgoingWebhook) (*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) SaveOutgoing(webhook *model.OutgoingWebhook) (*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(webhook)
|
||||
|
||||
var r0 *model.OutgoingWebhook
|
||||
@@ -529,20 +485,18 @@ func (_m *WebhookStore) SaveOutgoing(webhook *model.OutgoingWebhook) (*model.Out
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(*model.OutgoingWebhook) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(*model.OutgoingWebhook) error); ok {
|
||||
r1 = rf(webhook)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// UpdateIncoming provides a mock function with given fields: webhook
|
||||
func (_m *WebhookStore) UpdateIncoming(webhook *model.IncomingWebhook) (*model.IncomingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) UpdateIncoming(webhook *model.IncomingWebhook) (*model.IncomingWebhook, error) {
|
||||
ret := _m.Called(webhook)
|
||||
|
||||
var r0 *model.IncomingWebhook
|
||||
@@ -554,20 +508,18 @@ func (_m *WebhookStore) UpdateIncoming(webhook *model.IncomingWebhook) (*model.I
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(*model.IncomingWebhook) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(*model.IncomingWebhook) error); ok {
|
||||
r1 = rf(webhook)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
}
|
||||
|
||||
// UpdateOutgoing provides a mock function with given fields: hook
|
||||
func (_m *WebhookStore) UpdateOutgoing(hook *model.OutgoingWebhook) (*model.OutgoingWebhook, *model.AppError) {
|
||||
func (_m *WebhookStore) UpdateOutgoing(hook *model.OutgoingWebhook) (*model.OutgoingWebhook, error) {
|
||||
ret := _m.Called(hook)
|
||||
|
||||
var r0 *model.OutgoingWebhook
|
||||
@@ -579,13 +531,11 @@ func (_m *WebhookStore) UpdateOutgoing(hook *model.OutgoingWebhook) (*model.Outg
|
||||
}
|
||||
}
|
||||
|
||||
var r1 *model.AppError
|
||||
if rf, ok := ret.Get(1).(func(*model.OutgoingWebhook) *model.AppError); ok {
|
||||
var r1 error
|
||||
if rf, ok := ret.Get(1).(func(*model.OutgoingWebhook) error); ok {
|
||||
r1 = rf(hook)
|
||||
} else {
|
||||
if ret.Get(1) != nil {
|
||||
r1 = ret.Get(1).(*model.AppError)
|
||||
}
|
||||
r1 = ret.Error(1)
|
||||
}
|
||||
|
||||
return r0, r1
|
||||
|
||||
Ссылка в новой задаче
Block a user