github.com/onflow/flow-go@v0.35.7-crescendo-preview.23-atree-inlining/module/mock/epoch_lookup.go (about) 1 // Code generated by mockery v2.21.4. DO NOT EDIT. 2 3 package mock 4 5 import mock "github.com/stretchr/testify/mock" 6 7 // EpochLookup is an autogenerated mock type for the EpochLookup type 8 type EpochLookup struct { 9 mock.Mock 10 } 11 12 // EpochForViewWithFallback provides a mock function with given fields: view 13 func (_m *EpochLookup) EpochForViewWithFallback(view uint64) (uint64, error) { 14 ret := _m.Called(view) 15 16 var r0 uint64 17 var r1 error 18 if rf, ok := ret.Get(0).(func(uint64) (uint64, error)); ok { 19 return rf(view) 20 } 21 if rf, ok := ret.Get(0).(func(uint64) uint64); ok { 22 r0 = rf(view) 23 } else { 24 r0 = ret.Get(0).(uint64) 25 } 26 27 if rf, ok := ret.Get(1).(func(uint64) error); ok { 28 r1 = rf(view) 29 } else { 30 r1 = ret.Error(1) 31 } 32 33 return r0, r1 34 } 35 36 type mockConstructorTestingTNewEpochLookup interface { 37 mock.TestingT 38 Cleanup(func()) 39 } 40 41 // NewEpochLookup creates a new instance of EpochLookup. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 42 func NewEpochLookup(t mockConstructorTestingTNewEpochLookup) *EpochLookup { 43 mock := &EpochLookup{} 44 mock.Mock.Test(t) 45 46 t.Cleanup(func() { mock.AssertExpectations(t) }) 47 48 return mock 49 }