executors/kubernetes/mock_podWatcher.go (134 lines of code) (raw):
// Code generated by mockery v2.53.3. DO NOT EDIT.
package kubernetes
import mock "github.com/stretchr/testify/mock"
// mockPodWatcher is an autogenerated mock type for the podWatcher type
type mockPodWatcher struct {
mock.Mock
}
type mockPodWatcher_Expecter struct {
mock *mock.Mock
}
func (_m *mockPodWatcher) EXPECT() *mockPodWatcher_Expecter {
return &mockPodWatcher_Expecter{mock: &_m.Mock}
}
// Errors provides a mock function with no fields
func (_m *mockPodWatcher) Errors() <-chan error {
ret := _m.Called()
if len(ret) == 0 {
panic("no return value specified for Errors")
}
var r0 <-chan error
if rf, ok := ret.Get(0).(func() <-chan error); ok {
r0 = rf()
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(<-chan error)
}
}
return r0
}
// mockPodWatcher_Errors_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Errors'
type mockPodWatcher_Errors_Call struct {
*mock.Call
}
// Errors is a helper method to define mock.On call
func (_e *mockPodWatcher_Expecter) Errors() *mockPodWatcher_Errors_Call {
return &mockPodWatcher_Errors_Call{Call: _e.mock.On("Errors")}
}
func (_c *mockPodWatcher_Errors_Call) Run(run func()) *mockPodWatcher_Errors_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *mockPodWatcher_Errors_Call) Return(_a0 <-chan error) *mockPodWatcher_Errors_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *mockPodWatcher_Errors_Call) RunAndReturn(run func() <-chan error) *mockPodWatcher_Errors_Call {
_c.Call.Return(run)
return _c
}
// Start provides a mock function with no fields
func (_m *mockPodWatcher) Start() error {
ret := _m.Called()
if len(ret) == 0 {
panic("no return value specified for Start")
}
var r0 error
if rf, ok := ret.Get(0).(func() error); ok {
r0 = rf()
} else {
r0 = ret.Error(0)
}
return r0
}
// mockPodWatcher_Start_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Start'
type mockPodWatcher_Start_Call struct {
*mock.Call
}
// Start is a helper method to define mock.On call
func (_e *mockPodWatcher_Expecter) Start() *mockPodWatcher_Start_Call {
return &mockPodWatcher_Start_Call{Call: _e.mock.On("Start")}
}
func (_c *mockPodWatcher_Start_Call) Run(run func()) *mockPodWatcher_Start_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *mockPodWatcher_Start_Call) Return(_a0 error) *mockPodWatcher_Start_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *mockPodWatcher_Start_Call) RunAndReturn(run func() error) *mockPodWatcher_Start_Call {
_c.Call.Return(run)
return _c
}
// Stop provides a mock function with no fields
func (_m *mockPodWatcher) Stop() {
_m.Called()
}
// mockPodWatcher_Stop_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Stop'
type mockPodWatcher_Stop_Call struct {
*mock.Call
}
// Stop is a helper method to define mock.On call
func (_e *mockPodWatcher_Expecter) Stop() *mockPodWatcher_Stop_Call {
return &mockPodWatcher_Stop_Call{Call: _e.mock.On("Stop")}
}
func (_c *mockPodWatcher_Stop_Call) Run(run func()) *mockPodWatcher_Stop_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *mockPodWatcher_Stop_Call) Return() *mockPodWatcher_Stop_Call {
_c.Call.Return()
return _c
}
func (_c *mockPodWatcher_Stop_Call) RunAndReturn(run func()) *mockPodWatcher_Stop_Call {
_c.Run(run)
return _c
}
// UpdatePodName provides a mock function with given fields: _a0
func (_m *mockPodWatcher) UpdatePodName(_a0 string) {
_m.Called(_a0)
}
// mockPodWatcher_UpdatePodName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdatePodName'
type mockPodWatcher_UpdatePodName_Call struct {
*mock.Call
}
// UpdatePodName is a helper method to define mock.On call
// - _a0 string
func (_e *mockPodWatcher_Expecter) UpdatePodName(_a0 interface{}) *mockPodWatcher_UpdatePodName_Call {
return &mockPodWatcher_UpdatePodName_Call{Call: _e.mock.On("UpdatePodName", _a0)}
}
func (_c *mockPodWatcher_UpdatePodName_Call) Run(run func(_a0 string)) *mockPodWatcher_UpdatePodName_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *mockPodWatcher_UpdatePodName_Call) Return() *mockPodWatcher_UpdatePodName_Call {
_c.Call.Return()
return _c
}
func (_c *mockPodWatcher_UpdatePodName_Call) RunAndReturn(run func(string)) *mockPodWatcher_UpdatePodName_Call {
_c.Run(run)
return _c
}
// newMockPodWatcher creates a new instance of mockPodWatcher. 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 newMockPodWatcher(t interface {
mock.TestingT
Cleanup(func())
}) *mockPodWatcher {
mock := &mockPodWatcher{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}