helpers/runner_wrapper/api/proto/mock_ProcessWrapperServer.go (178 lines of code) (raw):
// Code generated by mockery v2.53.3. DO NOT EDIT.
package proto
import (
context "context"
mock "github.com/stretchr/testify/mock"
)
// MockProcessWrapperServer is an autogenerated mock type for the ProcessWrapperServer type
type MockProcessWrapperServer struct {
mock.Mock
}
type MockProcessWrapperServer_Expecter struct {
mock *mock.Mock
}
func (_m *MockProcessWrapperServer) EXPECT() *MockProcessWrapperServer_Expecter {
return &MockProcessWrapperServer_Expecter{mock: &_m.Mock}
}
// CheckStatus provides a mock function with given fields: _a0, _a1
func (_m *MockProcessWrapperServer) CheckStatus(_a0 context.Context, _a1 *CheckStatusRequest) (*CheckStatusResponse, error) {
ret := _m.Called(_a0, _a1)
if len(ret) == 0 {
panic("no return value specified for CheckStatus")
}
var r0 *CheckStatusResponse
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *CheckStatusRequest) (*CheckStatusResponse, error)); ok {
return rf(_a0, _a1)
}
if rf, ok := ret.Get(0).(func(context.Context, *CheckStatusRequest) *CheckStatusResponse); ok {
r0 = rf(_a0, _a1)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*CheckStatusResponse)
}
}
if rf, ok := ret.Get(1).(func(context.Context, *CheckStatusRequest) error); ok {
r1 = rf(_a0, _a1)
} else {
r1 = ret.Error(1)
}
return r0, r1
}
// MockProcessWrapperServer_CheckStatus_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckStatus'
type MockProcessWrapperServer_CheckStatus_Call struct {
*mock.Call
}
// CheckStatus is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *CheckStatusRequest
func (_e *MockProcessWrapperServer_Expecter) CheckStatus(_a0 interface{}, _a1 interface{}) *MockProcessWrapperServer_CheckStatus_Call {
return &MockProcessWrapperServer_CheckStatus_Call{Call: _e.mock.On("CheckStatus", _a0, _a1)}
}
func (_c *MockProcessWrapperServer_CheckStatus_Call) Run(run func(_a0 context.Context, _a1 *CheckStatusRequest)) *MockProcessWrapperServer_CheckStatus_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*CheckStatusRequest))
})
return _c
}
func (_c *MockProcessWrapperServer_CheckStatus_Call) Return(_a0 *CheckStatusResponse, _a1 error) *MockProcessWrapperServer_CheckStatus_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *MockProcessWrapperServer_CheckStatus_Call) RunAndReturn(run func(context.Context, *CheckStatusRequest) (*CheckStatusResponse, error)) *MockProcessWrapperServer_CheckStatus_Call {
_c.Call.Return(run)
return _c
}
// InitForcefulShutdown provides a mock function with given fields: _a0, _a1
func (_m *MockProcessWrapperServer) InitForcefulShutdown(_a0 context.Context, _a1 *InitForcefulShutdownRequest) (*InitForcefulShutdownResponse, error) {
ret := _m.Called(_a0, _a1)
if len(ret) == 0 {
panic("no return value specified for InitForcefulShutdown")
}
var r0 *InitForcefulShutdownResponse
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *InitForcefulShutdownRequest) (*InitForcefulShutdownResponse, error)); ok {
return rf(_a0, _a1)
}
if rf, ok := ret.Get(0).(func(context.Context, *InitForcefulShutdownRequest) *InitForcefulShutdownResponse); ok {
r0 = rf(_a0, _a1)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*InitForcefulShutdownResponse)
}
}
if rf, ok := ret.Get(1).(func(context.Context, *InitForcefulShutdownRequest) error); ok {
r1 = rf(_a0, _a1)
} else {
r1 = ret.Error(1)
}
return r0, r1
}
// MockProcessWrapperServer_InitForcefulShutdown_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InitForcefulShutdown'
type MockProcessWrapperServer_InitForcefulShutdown_Call struct {
*mock.Call
}
// InitForcefulShutdown is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *InitForcefulShutdownRequest
func (_e *MockProcessWrapperServer_Expecter) InitForcefulShutdown(_a0 interface{}, _a1 interface{}) *MockProcessWrapperServer_InitForcefulShutdown_Call {
return &MockProcessWrapperServer_InitForcefulShutdown_Call{Call: _e.mock.On("InitForcefulShutdown", _a0, _a1)}
}
func (_c *MockProcessWrapperServer_InitForcefulShutdown_Call) Run(run func(_a0 context.Context, _a1 *InitForcefulShutdownRequest)) *MockProcessWrapperServer_InitForcefulShutdown_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*InitForcefulShutdownRequest))
})
return _c
}
func (_c *MockProcessWrapperServer_InitForcefulShutdown_Call) Return(_a0 *InitForcefulShutdownResponse, _a1 error) *MockProcessWrapperServer_InitForcefulShutdown_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *MockProcessWrapperServer_InitForcefulShutdown_Call) RunAndReturn(run func(context.Context, *InitForcefulShutdownRequest) (*InitForcefulShutdownResponse, error)) *MockProcessWrapperServer_InitForcefulShutdown_Call {
_c.Call.Return(run)
return _c
}
// InitGracefulShutdown provides a mock function with given fields: _a0, _a1
func (_m *MockProcessWrapperServer) InitGracefulShutdown(_a0 context.Context, _a1 *InitGracefulShutdownRequest) (*InitGracefulShutdownResponse, error) {
ret := _m.Called(_a0, _a1)
if len(ret) == 0 {
panic("no return value specified for InitGracefulShutdown")
}
var r0 *InitGracefulShutdownResponse
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *InitGracefulShutdownRequest) (*InitGracefulShutdownResponse, error)); ok {
return rf(_a0, _a1)
}
if rf, ok := ret.Get(0).(func(context.Context, *InitGracefulShutdownRequest) *InitGracefulShutdownResponse); ok {
r0 = rf(_a0, _a1)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*InitGracefulShutdownResponse)
}
}
if rf, ok := ret.Get(1).(func(context.Context, *InitGracefulShutdownRequest) error); ok {
r1 = rf(_a0, _a1)
} else {
r1 = ret.Error(1)
}
return r0, r1
}
// MockProcessWrapperServer_InitGracefulShutdown_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InitGracefulShutdown'
type MockProcessWrapperServer_InitGracefulShutdown_Call struct {
*mock.Call
}
// InitGracefulShutdown is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *InitGracefulShutdownRequest
func (_e *MockProcessWrapperServer_Expecter) InitGracefulShutdown(_a0 interface{}, _a1 interface{}) *MockProcessWrapperServer_InitGracefulShutdown_Call {
return &MockProcessWrapperServer_InitGracefulShutdown_Call{Call: _e.mock.On("InitGracefulShutdown", _a0, _a1)}
}
func (_c *MockProcessWrapperServer_InitGracefulShutdown_Call) Run(run func(_a0 context.Context, _a1 *InitGracefulShutdownRequest)) *MockProcessWrapperServer_InitGracefulShutdown_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*InitGracefulShutdownRequest))
})
return _c
}
func (_c *MockProcessWrapperServer_InitGracefulShutdown_Call) Return(_a0 *InitGracefulShutdownResponse, _a1 error) *MockProcessWrapperServer_InitGracefulShutdown_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *MockProcessWrapperServer_InitGracefulShutdown_Call) RunAndReturn(run func(context.Context, *InitGracefulShutdownRequest) (*InitGracefulShutdownResponse, error)) *MockProcessWrapperServer_InitGracefulShutdown_Call {
_c.Call.Return(run)
return _c
}
// mustEmbedUnimplementedProcessWrapperServer provides a mock function with no fields
func (_m *MockProcessWrapperServer) mustEmbedUnimplementedProcessWrapperServer() {
_m.Called()
}
// MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'mustEmbedUnimplementedProcessWrapperServer'
type MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call struct {
*mock.Call
}
// mustEmbedUnimplementedProcessWrapperServer is a helper method to define mock.On call
func (_e *MockProcessWrapperServer_Expecter) mustEmbedUnimplementedProcessWrapperServer() *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call {
return &MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call{Call: _e.mock.On("mustEmbedUnimplementedProcessWrapperServer")}
}
func (_c *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call) Run(run func()) *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call) Return() *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call {
_c.Call.Return()
return _c
}
func (_c *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call) RunAndReturn(run func()) *MockProcessWrapperServer_mustEmbedUnimplementedProcessWrapperServer_Call {
_c.Run(run)
return _c
}
// NewMockProcessWrapperServer creates a new instance of MockProcessWrapperServer. 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 NewMockProcessWrapperServer(t interface {
mock.TestingT
Cleanup(func())
}) *MockProcessWrapperServer {
mock := &MockProcessWrapperServer{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}