mirror of
https://github.com/tnb-labs/panel.git
synced 2026-08-30 17:05:19 +08:00
chore: update mocks
This commit is contained in:
committed by
github-actions[bot]
parent
37c155acb5
commit
5407c53619
+18
-16
@@ -168,9 +168,9 @@ func (_c *ScanEventRepo_GetSetting_Call) RunAndReturn(run func() (*biz.ScanSetti
|
||||
return _c
|
||||
}
|
||||
|
||||
// List provides a mock function with given fields: start, end, page, limit
|
||||
func (_m *ScanEventRepo) List(start string, end string, page uint, limit uint) ([]*biz.ScanEvent, uint, error) {
|
||||
ret := _m.Called(start, end, page, limit)
|
||||
// List provides a mock function with given fields: start, end, sourceIP, port, page, limit
|
||||
func (_m *ScanEventRepo) List(start string, end string, sourceIP string, port uint, page uint, limit uint) ([]*biz.ScanEvent, uint, error) {
|
||||
ret := _m.Called(start, end, sourceIP, port, page, limit)
|
||||
|
||||
if len(ret) == 0 {
|
||||
panic("no return value specified for List")
|
||||
@@ -179,25 +179,25 @@ func (_m *ScanEventRepo) List(start string, end string, page uint, limit uint) (
|
||||
var r0 []*biz.ScanEvent
|
||||
var r1 uint
|
||||
var r2 error
|
||||
if rf, ok := ret.Get(0).(func(string, string, uint, uint) ([]*biz.ScanEvent, uint, error)); ok {
|
||||
return rf(start, end, page, limit)
|
||||
if rf, ok := ret.Get(0).(func(string, string, string, uint, uint, uint) ([]*biz.ScanEvent, uint, error)); ok {
|
||||
return rf(start, end, sourceIP, port, page, limit)
|
||||
}
|
||||
if rf, ok := ret.Get(0).(func(string, string, uint, uint) []*biz.ScanEvent); ok {
|
||||
r0 = rf(start, end, page, limit)
|
||||
if rf, ok := ret.Get(0).(func(string, string, string, uint, uint, uint) []*biz.ScanEvent); ok {
|
||||
r0 = rf(start, end, sourceIP, port, page, limit)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).([]*biz.ScanEvent)
|
||||
}
|
||||
}
|
||||
|
||||
if rf, ok := ret.Get(1).(func(string, string, uint, uint) uint); ok {
|
||||
r1 = rf(start, end, page, limit)
|
||||
if rf, ok := ret.Get(1).(func(string, string, string, uint, uint, uint) uint); ok {
|
||||
r1 = rf(start, end, sourceIP, port, page, limit)
|
||||
} else {
|
||||
r1 = ret.Get(1).(uint)
|
||||
}
|
||||
|
||||
if rf, ok := ret.Get(2).(func(string, string, uint, uint) error); ok {
|
||||
r2 = rf(start, end, page, limit)
|
||||
if rf, ok := ret.Get(2).(func(string, string, string, uint, uint, uint) error); ok {
|
||||
r2 = rf(start, end, sourceIP, port, page, limit)
|
||||
} else {
|
||||
r2 = ret.Error(2)
|
||||
}
|
||||
@@ -213,15 +213,17 @@ type ScanEventRepo_List_Call struct {
|
||||
// List is a helper method to define mock.On call
|
||||
// - start string
|
||||
// - end string
|
||||
// - sourceIP string
|
||||
// - port uint
|
||||
// - page uint
|
||||
// - limit uint
|
||||
func (_e *ScanEventRepo_Expecter) List(start interface{}, end interface{}, page interface{}, limit interface{}) *ScanEventRepo_List_Call {
|
||||
return &ScanEventRepo_List_Call{Call: _e.mock.On("List", start, end, page, limit)}
|
||||
func (_e *ScanEventRepo_Expecter) List(start interface{}, end interface{}, sourceIP interface{}, port interface{}, page interface{}, limit interface{}) *ScanEventRepo_List_Call {
|
||||
return &ScanEventRepo_List_Call{Call: _e.mock.On("List", start, end, sourceIP, port, page, limit)}
|
||||
}
|
||||
|
||||
func (_c *ScanEventRepo_List_Call) Run(run func(start string, end string, page uint, limit uint)) *ScanEventRepo_List_Call {
|
||||
func (_c *ScanEventRepo_List_Call) Run(run func(start string, end string, sourceIP string, port uint, page uint, limit uint)) *ScanEventRepo_List_Call {
|
||||
_c.Call.Run(func(args mock.Arguments) {
|
||||
run(args[0].(string), args[1].(string), args[2].(uint), args[3].(uint))
|
||||
run(args[0].(string), args[1].(string), args[2].(string), args[3].(uint), args[4].(uint), args[5].(uint))
|
||||
})
|
||||
return _c
|
||||
}
|
||||
@@ -231,7 +233,7 @@ func (_c *ScanEventRepo_List_Call) Return(_a0 []*biz.ScanEvent, _a1 uint, _a2 er
|
||||
return _c
|
||||
}
|
||||
|
||||
func (_c *ScanEventRepo_List_Call) RunAndReturn(run func(string, string, uint, uint) ([]*biz.ScanEvent, uint, error)) *ScanEventRepo_List_Call {
|
||||
func (_c *ScanEventRepo_List_Call) RunAndReturn(run func(string, string, string, uint, uint, uint) ([]*biz.ScanEvent, uint, error)) *ScanEventRepo_List_Call {
|
||||
_c.Call.Return(run)
|
||||
return _c
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user