diff options
Diffstat (limited to 'pkg/coveragedb/mocks/Row.go')
| -rw-r--r-- | pkg/coveragedb/mocks/Row.go | 61 |
1 files changed, 35 insertions, 26 deletions
diff --git a/pkg/coveragedb/mocks/Row.go b/pkg/coveragedb/mocks/Row.go index 549e7d214..3ea716173 100644 --- a/pkg/coveragedb/mocks/Row.go +++ b/pkg/coveragedb/mocks/Row.go @@ -1,8 +1,26 @@ -// Code generated by mockery v2.52.1. DO NOT EDIT. +// Code generated by mockery; DO NOT EDIT. +// github.com/vektra/mockery +// template: testify package mocks -import mock "github.com/stretchr/testify/mock" +import ( + mock "github.com/stretchr/testify/mock" +) + +// NewRow creates a new instance of Row. 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 NewRow(t interface { + mock.TestingT + Cleanup(func()) +}) *Row { + mock := &Row{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} // Row is an autogenerated mock type for the Row type type Row struct { @@ -17,21 +35,20 @@ func (_m *Row) EXPECT() *Row_Expecter { return &Row_Expecter{mock: &_m.Mock} } -// ToStruct provides a mock function with given fields: p -func (_m *Row) ToStruct(p interface{}) error { - ret := _m.Called(p) +// ToStruct provides a mock function for the type Row +func (_mock *Row) ToStruct(p interface{}) error { + ret := _mock.Called(p) if len(ret) == 0 { panic("no return value specified for ToStruct") } var r0 error - if rf, ok := ret.Get(0).(func(interface{}) error); ok { - r0 = rf(p) + if returnFunc, ok := ret.Get(0).(func(interface{}) error); ok { + r0 = returnFunc(p) } else { r0 = ret.Error(0) } - return r0 } @@ -48,31 +65,23 @@ func (_e *Row_Expecter) ToStruct(p interface{}) *Row_ToStruct_Call { func (_c *Row_ToStruct_Call) Run(run func(p interface{})) *Row_ToStruct_Call { _c.Call.Run(func(args mock.Arguments) { - run(args[0].(interface{})) + var arg0 interface{} + if args[0] != nil { + arg0 = args[0].(interface{}) + } + run( + arg0, + ) }) return _c } -func (_c *Row_ToStruct_Call) Return(_a0 error) *Row_ToStruct_Call { - _c.Call.Return(_a0) +func (_c *Row_ToStruct_Call) Return(err error) *Row_ToStruct_Call { + _c.Call.Return(err) return _c } -func (_c *Row_ToStruct_Call) RunAndReturn(run func(interface{}) error) *Row_ToStruct_Call { +func (_c *Row_ToStruct_Call) RunAndReturn(run func(p interface{}) error) *Row_ToStruct_Call { _c.Call.Return(run) return _c } - -// NewRow creates a new instance of Row. 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 NewRow(t interface { - mock.TestingT - Cleanup(func()) -}) *Row { - mock := &Row{} - mock.Mock.Test(t) - - t.Cleanup(func() { mock.AssertExpectations(t) }) - - return mock -} |
