mirror of
https://github.com/tnb-labs/panel.git
synced 2026-08-29 02:10:58 +08:00
3ce353e8e4
mockery v2 已 EOL,其内嵌的旧版 x/tools 无法解析 Go 1.27 的 export data, 导致 Mockery workflow 在 stable 切到 1.27.0 后持续失败。 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
616 lines
17 KiB
Go
616 lines
17 KiB
Go
// Code generated by mockery; DO NOT EDIT.
|
|
// github.com/vektra/mockery
|
|
// template: testify
|
|
|
|
package biz
|
|
|
|
import (
|
|
"github.com/acepanel/panel/v3/internal/biz"
|
|
mock "github.com/stretchr/testify/mock"
|
|
)
|
|
|
|
// NewScanEventRepo creates a new instance of ScanEventRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
|
|
// The first argument is typically a *testing.T value.
|
|
func NewScanEventRepo(t interface {
|
|
mock.TestingT
|
|
Cleanup(func())
|
|
}) *ScanEventRepo {
|
|
mock := &ScanEventRepo{}
|
|
mock.Mock.Test(t)
|
|
|
|
t.Cleanup(func() { mock.AssertExpectations(t) })
|
|
|
|
return mock
|
|
}
|
|
|
|
// ScanEventRepo is an autogenerated mock type for the ScanEventRepo type
|
|
type ScanEventRepo struct {
|
|
mock.Mock
|
|
}
|
|
|
|
type ScanEventRepo_Expecter struct {
|
|
mock *mock.Mock
|
|
}
|
|
|
|
func (_m *ScanEventRepo) EXPECT() *ScanEventRepo_Expecter {
|
|
return &ScanEventRepo_Expecter{mock: &_m.Mock}
|
|
}
|
|
|
|
// Clear provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) Clear() error {
|
|
ret := _mock.Called()
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for Clear")
|
|
}
|
|
|
|
var r0 error
|
|
if returnFunc, ok := ret.Get(0).(func() error); ok {
|
|
r0 = returnFunc()
|
|
} else {
|
|
r0 = ret.Error(0)
|
|
}
|
|
return r0
|
|
}
|
|
|
|
// ScanEventRepo_Clear_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Clear'
|
|
type ScanEventRepo_Clear_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Clear is a helper method to define mock.On call
|
|
func (_e *ScanEventRepo_Expecter) Clear() *ScanEventRepo_Clear_Call {
|
|
return &ScanEventRepo_Clear_Call{Call: _e.mock.On("Clear")}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Clear_Call) Run(run func()) *ScanEventRepo_Clear_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
run()
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Clear_Call) Return(err error) *ScanEventRepo_Clear_Call {
|
|
_c.Call.Return(err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Clear_Call) RunAndReturn(run func() error) *ScanEventRepo_Clear_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// ClearBefore provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) ClearBefore(date string) error {
|
|
ret := _mock.Called(date)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for ClearBefore")
|
|
}
|
|
|
|
var r0 error
|
|
if returnFunc, ok := ret.Get(0).(func(string) error); ok {
|
|
r0 = returnFunc(date)
|
|
} else {
|
|
r0 = ret.Error(0)
|
|
}
|
|
return r0
|
|
}
|
|
|
|
// ScanEventRepo_ClearBefore_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ClearBefore'
|
|
type ScanEventRepo_ClearBefore_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// ClearBefore is a helper method to define mock.On call
|
|
// - date string
|
|
func (_e *ScanEventRepo_Expecter) ClearBefore(date any) *ScanEventRepo_ClearBefore_Call {
|
|
return &ScanEventRepo_ClearBefore_Call{Call: _e.mock.On("ClearBefore", date)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_ClearBefore_Call) Run(run func(date string)) *ScanEventRepo_ClearBefore_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
run(
|
|
arg0,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_ClearBefore_Call) Return(err error) *ScanEventRepo_ClearBefore_Call {
|
|
_c.Call.Return(err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_ClearBefore_Call) RunAndReturn(run func(date string) error) *ScanEventRepo_ClearBefore_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// List provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) List(start string, end string, sourceIP string, port uint, location string, page uint, limit uint) ([]*biz.ScanEvent, uint, error) {
|
|
ret := _mock.Called(start, end, sourceIP, port, location, page, limit)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for List")
|
|
}
|
|
|
|
var r0 []*biz.ScanEvent
|
|
var r1 uint
|
|
var r2 error
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, string, uint, string, uint, uint) ([]*biz.ScanEvent, uint, error)); ok {
|
|
return returnFunc(start, end, sourceIP, port, location, page, limit)
|
|
}
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, string, uint, string, uint, uint) []*biz.ScanEvent); ok {
|
|
r0 = returnFunc(start, end, sourceIP, port, location, page, limit)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).([]*biz.ScanEvent)
|
|
}
|
|
}
|
|
if returnFunc, ok := ret.Get(1).(func(string, string, string, uint, string, uint, uint) uint); ok {
|
|
r1 = returnFunc(start, end, sourceIP, port, location, page, limit)
|
|
} else {
|
|
r1 = ret.Get(1).(uint)
|
|
}
|
|
if returnFunc, ok := ret.Get(2).(func(string, string, string, uint, string, uint, uint) error); ok {
|
|
r2 = returnFunc(start, end, sourceIP, port, location, page, limit)
|
|
} else {
|
|
r2 = ret.Error(2)
|
|
}
|
|
return r0, r1, r2
|
|
}
|
|
|
|
// ScanEventRepo_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
|
|
type ScanEventRepo_List_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// List is a helper method to define mock.On call
|
|
// - start string
|
|
// - end string
|
|
// - sourceIP string
|
|
// - port uint
|
|
// - location string
|
|
// - page uint
|
|
// - limit uint
|
|
func (_e *ScanEventRepo_Expecter) List(start any, end any, sourceIP any, port any, location any, page any, limit any) *ScanEventRepo_List_Call {
|
|
return &ScanEventRepo_List_Call{Call: _e.mock.On("List", start, end, sourceIP, port, location, page, limit)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_List_Call) Run(run func(start string, end string, sourceIP string, port uint, location string, page uint, limit uint)) *ScanEventRepo_List_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
var arg1 string
|
|
if args[1] != nil {
|
|
arg1 = args[1].(string)
|
|
}
|
|
var arg2 string
|
|
if args[2] != nil {
|
|
arg2 = args[2].(string)
|
|
}
|
|
var arg3 uint
|
|
if args[3] != nil {
|
|
arg3 = args[3].(uint)
|
|
}
|
|
var arg4 string
|
|
if args[4] != nil {
|
|
arg4 = args[4].(string)
|
|
}
|
|
var arg5 uint
|
|
if args[5] != nil {
|
|
arg5 = args[5].(uint)
|
|
}
|
|
var arg6 uint
|
|
if args[6] != nil {
|
|
arg6 = args[6].(uint)
|
|
}
|
|
run(
|
|
arg0,
|
|
arg1,
|
|
arg2,
|
|
arg3,
|
|
arg4,
|
|
arg5,
|
|
arg6,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_List_Call) Return(scanEvents []*biz.ScanEvent, v uint, err error) *ScanEventRepo_List_Call {
|
|
_c.Call.Return(scanEvents, v, err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_List_Call) RunAndReturn(run func(start string, end string, sourceIP string, port uint, location string, page uint, limit uint) ([]*biz.ScanEvent, uint, error)) *ScanEventRepo_List_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Summary provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) Summary(start string, end string) (*biz.ScanSummary, error) {
|
|
ret := _mock.Called(start, end)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for Summary")
|
|
}
|
|
|
|
var r0 *biz.ScanSummary
|
|
var r1 error
|
|
if returnFunc, ok := ret.Get(0).(func(string, string) (*biz.ScanSummary, error)); ok {
|
|
return returnFunc(start, end)
|
|
}
|
|
if returnFunc, ok := ret.Get(0).(func(string, string) *biz.ScanSummary); ok {
|
|
r0 = returnFunc(start, end)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).(*biz.ScanSummary)
|
|
}
|
|
}
|
|
if returnFunc, ok := ret.Get(1).(func(string, string) error); ok {
|
|
r1 = returnFunc(start, end)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
return r0, r1
|
|
}
|
|
|
|
// ScanEventRepo_Summary_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Summary'
|
|
type ScanEventRepo_Summary_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Summary is a helper method to define mock.On call
|
|
// - start string
|
|
// - end string
|
|
func (_e *ScanEventRepo_Expecter) Summary(start any, end any) *ScanEventRepo_Summary_Call {
|
|
return &ScanEventRepo_Summary_Call{Call: _e.mock.On("Summary", start, end)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Summary_Call) Run(run func(start string, end string)) *ScanEventRepo_Summary_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
var arg1 string
|
|
if args[1] != nil {
|
|
arg1 = args[1].(string)
|
|
}
|
|
run(
|
|
arg0,
|
|
arg1,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Summary_Call) Return(scanSummary *biz.ScanSummary, err error) *ScanEventRepo_Summary_Call {
|
|
_c.Call.Return(scanSummary, err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Summary_Call) RunAndReturn(run func(start string, end string) (*biz.ScanSummary, error)) *ScanEventRepo_Summary_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// TopPorts provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) TopPorts(start string, end string, limit uint) ([]*biz.ScanPortRank, error) {
|
|
ret := _mock.Called(start, end, limit)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for TopPorts")
|
|
}
|
|
|
|
var r0 []*biz.ScanPortRank
|
|
var r1 error
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, uint) ([]*biz.ScanPortRank, error)); ok {
|
|
return returnFunc(start, end, limit)
|
|
}
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, uint) []*biz.ScanPortRank); ok {
|
|
r0 = returnFunc(start, end, limit)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).([]*biz.ScanPortRank)
|
|
}
|
|
}
|
|
if returnFunc, ok := ret.Get(1).(func(string, string, uint) error); ok {
|
|
r1 = returnFunc(start, end, limit)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
return r0, r1
|
|
}
|
|
|
|
// ScanEventRepo_TopPorts_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TopPorts'
|
|
type ScanEventRepo_TopPorts_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// TopPorts is a helper method to define mock.On call
|
|
// - start string
|
|
// - end string
|
|
// - limit uint
|
|
func (_e *ScanEventRepo_Expecter) TopPorts(start any, end any, limit any) *ScanEventRepo_TopPorts_Call {
|
|
return &ScanEventRepo_TopPorts_Call{Call: _e.mock.On("TopPorts", start, end, limit)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopPorts_Call) Run(run func(start string, end string, limit uint)) *ScanEventRepo_TopPorts_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
var arg1 string
|
|
if args[1] != nil {
|
|
arg1 = args[1].(string)
|
|
}
|
|
var arg2 uint
|
|
if args[2] != nil {
|
|
arg2 = args[2].(uint)
|
|
}
|
|
run(
|
|
arg0,
|
|
arg1,
|
|
arg2,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopPorts_Call) Return(scanPortRanks []*biz.ScanPortRank, err error) *ScanEventRepo_TopPorts_Call {
|
|
_c.Call.Return(scanPortRanks, err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopPorts_Call) RunAndReturn(run func(start string, end string, limit uint) ([]*biz.ScanPortRank, error)) *ScanEventRepo_TopPorts_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// TopSourceIPs provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) TopSourceIPs(start string, end string, limit uint) ([]*biz.ScanSourceRank, error) {
|
|
ret := _mock.Called(start, end, limit)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for TopSourceIPs")
|
|
}
|
|
|
|
var r0 []*biz.ScanSourceRank
|
|
var r1 error
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, uint) ([]*biz.ScanSourceRank, error)); ok {
|
|
return returnFunc(start, end, limit)
|
|
}
|
|
if returnFunc, ok := ret.Get(0).(func(string, string, uint) []*biz.ScanSourceRank); ok {
|
|
r0 = returnFunc(start, end, limit)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).([]*biz.ScanSourceRank)
|
|
}
|
|
}
|
|
if returnFunc, ok := ret.Get(1).(func(string, string, uint) error); ok {
|
|
r1 = returnFunc(start, end, limit)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
return r0, r1
|
|
}
|
|
|
|
// ScanEventRepo_TopSourceIPs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TopSourceIPs'
|
|
type ScanEventRepo_TopSourceIPs_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// TopSourceIPs is a helper method to define mock.On call
|
|
// - start string
|
|
// - end string
|
|
// - limit uint
|
|
func (_e *ScanEventRepo_Expecter) TopSourceIPs(start any, end any, limit any) *ScanEventRepo_TopSourceIPs_Call {
|
|
return &ScanEventRepo_TopSourceIPs_Call{Call: _e.mock.On("TopSourceIPs", start, end, limit)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopSourceIPs_Call) Run(run func(start string, end string, limit uint)) *ScanEventRepo_TopSourceIPs_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
var arg1 string
|
|
if args[1] != nil {
|
|
arg1 = args[1].(string)
|
|
}
|
|
var arg2 uint
|
|
if args[2] != nil {
|
|
arg2 = args[2].(uint)
|
|
}
|
|
run(
|
|
arg0,
|
|
arg1,
|
|
arg2,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopSourceIPs_Call) Return(scanSourceRanks []*biz.ScanSourceRank, err error) *ScanEventRepo_TopSourceIPs_Call {
|
|
_c.Call.Return(scanSourceRanks, err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_TopSourceIPs_Call) RunAndReturn(run func(start string, end string, limit uint) ([]*biz.ScanSourceRank, error)) *ScanEventRepo_TopSourceIPs_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Trend provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) Trend(start string, end string) ([]*biz.ScanDayTrend, error) {
|
|
ret := _mock.Called(start, end)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for Trend")
|
|
}
|
|
|
|
var r0 []*biz.ScanDayTrend
|
|
var r1 error
|
|
if returnFunc, ok := ret.Get(0).(func(string, string) ([]*biz.ScanDayTrend, error)); ok {
|
|
return returnFunc(start, end)
|
|
}
|
|
if returnFunc, ok := ret.Get(0).(func(string, string) []*biz.ScanDayTrend); ok {
|
|
r0 = returnFunc(start, end)
|
|
} else {
|
|
if ret.Get(0) != nil {
|
|
r0 = ret.Get(0).([]*biz.ScanDayTrend)
|
|
}
|
|
}
|
|
if returnFunc, ok := ret.Get(1).(func(string, string) error); ok {
|
|
r1 = returnFunc(start, end)
|
|
} else {
|
|
r1 = ret.Error(1)
|
|
}
|
|
return r0, r1
|
|
}
|
|
|
|
// ScanEventRepo_Trend_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Trend'
|
|
type ScanEventRepo_Trend_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Trend is a helper method to define mock.On call
|
|
// - start string
|
|
// - end string
|
|
func (_e *ScanEventRepo_Expecter) Trend(start any, end any) *ScanEventRepo_Trend_Call {
|
|
return &ScanEventRepo_Trend_Call{Call: _e.mock.On("Trend", start, end)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Trend_Call) Run(run func(start string, end string)) *ScanEventRepo_Trend_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 string
|
|
if args[0] != nil {
|
|
arg0 = args[0].(string)
|
|
}
|
|
var arg1 string
|
|
if args[1] != nil {
|
|
arg1 = args[1].(string)
|
|
}
|
|
run(
|
|
arg0,
|
|
arg1,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Trend_Call) Return(scanDayTrends []*biz.ScanDayTrend, err error) *ScanEventRepo_Trend_Call {
|
|
_c.Call.Return(scanDayTrends, err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Trend_Call) RunAndReturn(run func(start string, end string) ([]*biz.ScanDayTrend, error)) *ScanEventRepo_Trend_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// Upsert provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) Upsert(events []*biz.ScanEvent) error {
|
|
ret := _mock.Called(events)
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for Upsert")
|
|
}
|
|
|
|
var r0 error
|
|
if returnFunc, ok := ret.Get(0).(func([]*biz.ScanEvent) error); ok {
|
|
r0 = returnFunc(events)
|
|
} else {
|
|
r0 = ret.Error(0)
|
|
}
|
|
return r0
|
|
}
|
|
|
|
// ScanEventRepo_Upsert_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Upsert'
|
|
type ScanEventRepo_Upsert_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// Upsert is a helper method to define mock.On call
|
|
// - events []*biz.ScanEvent
|
|
func (_e *ScanEventRepo_Expecter) Upsert(events any) *ScanEventRepo_Upsert_Call {
|
|
return &ScanEventRepo_Upsert_Call{Call: _e.mock.On("Upsert", events)}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Upsert_Call) Run(run func(events []*biz.ScanEvent)) *ScanEventRepo_Upsert_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
var arg0 []*biz.ScanEvent
|
|
if args[0] != nil {
|
|
arg0 = args[0].([]*biz.ScanEvent)
|
|
}
|
|
run(
|
|
arg0,
|
|
)
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Upsert_Call) Return(err error) *ScanEventRepo_Upsert_Call {
|
|
_c.Call.Return(err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_Upsert_Call) RunAndReturn(run func(events []*biz.ScanEvent) error) *ScanEventRepo_Upsert_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|
|
|
|
// VacuumDB provides a mock function for the type ScanEventRepo
|
|
func (_mock *ScanEventRepo) VacuumDB() error {
|
|
ret := _mock.Called()
|
|
|
|
if len(ret) == 0 {
|
|
panic("no return value specified for VacuumDB")
|
|
}
|
|
|
|
var r0 error
|
|
if returnFunc, ok := ret.Get(0).(func() error); ok {
|
|
r0 = returnFunc()
|
|
} else {
|
|
r0 = ret.Error(0)
|
|
}
|
|
return r0
|
|
}
|
|
|
|
// ScanEventRepo_VacuumDB_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'VacuumDB'
|
|
type ScanEventRepo_VacuumDB_Call struct {
|
|
*mock.Call
|
|
}
|
|
|
|
// VacuumDB is a helper method to define mock.On call
|
|
func (_e *ScanEventRepo_Expecter) VacuumDB() *ScanEventRepo_VacuumDB_Call {
|
|
return &ScanEventRepo_VacuumDB_Call{Call: _e.mock.On("VacuumDB")}
|
|
}
|
|
|
|
func (_c *ScanEventRepo_VacuumDB_Call) Run(run func()) *ScanEventRepo_VacuumDB_Call {
|
|
_c.Call.Run(func(args mock.Arguments) {
|
|
run()
|
|
})
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_VacuumDB_Call) Return(err error) *ScanEventRepo_VacuumDB_Call {
|
|
_c.Call.Return(err)
|
|
return _c
|
|
}
|
|
|
|
func (_c *ScanEventRepo_VacuumDB_Call) RunAndReturn(run func() error) *ScanEventRepo_VacuumDB_Call {
|
|
_c.Call.Return(run)
|
|
return _c
|
|
}
|