2021-04-01 18:46:45 +00:00
|
|
|
// Code generated by mockery v2.7.4. DO NOT EDIT.
|
|
|
|
|
|
|
|
package media
|
|
|
|
|
|
|
|
import (
|
|
|
|
mock "github.com/stretchr/testify/mock"
|
2021-04-19 17:42:19 +00:00
|
|
|
gtsmodel "github.com/superseriousbusiness/gotosocial/internal/db/gtsmodel"
|
2021-04-01 18:46:45 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
// MockMediaHandler is an autogenerated mock type for the MediaHandler type
|
|
|
|
type MockMediaHandler struct {
|
|
|
|
mock.Mock
|
|
|
|
}
|
|
|
|
|
2021-04-19 17:42:19 +00:00
|
|
|
// ProcessAttachment provides a mock function with given fields: img, accountID
|
|
|
|
func (_m *MockMediaHandler) ProcessAttachment(img []byte, accountID string) (*gtsmodel.MediaAttachment, error) {
|
|
|
|
ret := _m.Called(img, accountID)
|
|
|
|
|
|
|
|
var r0 *gtsmodel.MediaAttachment
|
|
|
|
if rf, ok := ret.Get(0).(func([]byte, string) *gtsmodel.MediaAttachment); ok {
|
|
|
|
r0 = rf(img, accountID)
|
|
|
|
} else {
|
|
|
|
if ret.Get(0) != nil {
|
|
|
|
r0 = ret.Get(0).(*gtsmodel.MediaAttachment)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
var r1 error
|
|
|
|
if rf, ok := ret.Get(1).(func([]byte, string) error); ok {
|
|
|
|
r1 = rf(img, accountID)
|
|
|
|
} else {
|
|
|
|
r1 = ret.Error(1)
|
|
|
|
}
|
|
|
|
|
|
|
|
return r0, r1
|
|
|
|
}
|
|
|
|
|
2021-04-01 18:46:45 +00:00
|
|
|
// SetHeaderOrAvatarForAccountID provides a mock function with given fields: img, accountID, headerOrAvi
|
2021-04-19 17:42:19 +00:00
|
|
|
func (_m *MockMediaHandler) SetHeaderOrAvatarForAccountID(img []byte, accountID string, headerOrAvi string) (*gtsmodel.MediaAttachment, error) {
|
2021-04-01 18:46:45 +00:00
|
|
|
ret := _m.Called(img, accountID, headerOrAvi)
|
|
|
|
|
2021-04-19 17:42:19 +00:00
|
|
|
var r0 *gtsmodel.MediaAttachment
|
|
|
|
if rf, ok := ret.Get(0).(func([]byte, string, string) *gtsmodel.MediaAttachment); ok {
|
2021-04-01 18:46:45 +00:00
|
|
|
r0 = rf(img, accountID, headerOrAvi)
|
|
|
|
} else {
|
|
|
|
if ret.Get(0) != nil {
|
2021-04-19 17:42:19 +00:00
|
|
|
r0 = ret.Get(0).(*gtsmodel.MediaAttachment)
|
2021-04-01 18:46:45 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
var r1 error
|
|
|
|
if rf, ok := ret.Get(1).(func([]byte, string, string) error); ok {
|
|
|
|
r1 = rf(img, accountID, headerOrAvi)
|
|
|
|
} else {
|
|
|
|
r1 = ret.Error(1)
|
|
|
|
}
|
|
|
|
|
|
|
|
return r0, r1
|
|
|
|
}
|