github.com/onflow/flow-go@v0.35.7-crescendo-preview.23-atree-inlining/module/mock/jobs.go (about) 1 // Code generated by mockery v2.21.4. DO NOT EDIT. 2 3 package mock 4 5 import ( 6 module "github.com/onflow/flow-go/module" 7 mock "github.com/stretchr/testify/mock" 8 ) 9 10 // Jobs is an autogenerated mock type for the Jobs type 11 type Jobs struct { 12 mock.Mock 13 } 14 15 // AtIndex provides a mock function with given fields: index 16 func (_m *Jobs) AtIndex(index uint64) (module.Job, error) { 17 ret := _m.Called(index) 18 19 var r0 module.Job 20 var r1 error 21 if rf, ok := ret.Get(0).(func(uint64) (module.Job, error)); ok { 22 return rf(index) 23 } 24 if rf, ok := ret.Get(0).(func(uint64) module.Job); ok { 25 r0 = rf(index) 26 } else { 27 if ret.Get(0) != nil { 28 r0 = ret.Get(0).(module.Job) 29 } 30 } 31 32 if rf, ok := ret.Get(1).(func(uint64) error); ok { 33 r1 = rf(index) 34 } else { 35 r1 = ret.Error(1) 36 } 37 38 return r0, r1 39 } 40 41 // Head provides a mock function with given fields: 42 func (_m *Jobs) Head() (uint64, error) { 43 ret := _m.Called() 44 45 var r0 uint64 46 var r1 error 47 if rf, ok := ret.Get(0).(func() (uint64, error)); ok { 48 return rf() 49 } 50 if rf, ok := ret.Get(0).(func() uint64); ok { 51 r0 = rf() 52 } else { 53 r0 = ret.Get(0).(uint64) 54 } 55 56 if rf, ok := ret.Get(1).(func() error); ok { 57 r1 = rf() 58 } else { 59 r1 = ret.Error(1) 60 } 61 62 return r0, r1 63 } 64 65 type mockConstructorTestingTNewJobs interface { 66 mock.TestingT 67 Cleanup(func()) 68 } 69 70 // NewJobs creates a new instance of Jobs. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 71 func NewJobs(t mockConstructorTestingTNewJobs) *Jobs { 72 mock := &Jobs{} 73 mock.Mock.Test(t) 74 75 t.Cleanup(func() { mock.AssertExpectations(t) }) 76 77 return mock 78 }