Files
tidb/pkg/dxf/framework/mock/execute/execute_mock.go

240 lines
8.4 KiB
Go

// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/pingcap/tidb/pkg/dxf/framework/taskexecutor/execute (interfaces: StepExecutor)
//
// Generated by this command:
//
// mockgen -embed -package mockexecute github.com/pingcap/tidb/pkg/dxf/framework/taskexecutor/execute StepExecutor
//
// Package mockexecute is a generated GoMock package.
package mockexecute
import (
context "context"
reflect "reflect"
metering "github.com/pingcap/tidb/pkg/dxf/framework/metering"
proto "github.com/pingcap/tidb/pkg/dxf/framework/proto"
execute "github.com/pingcap/tidb/pkg/dxf/framework/taskexecutor/execute"
gomock "go.uber.org/mock/gomock"
)
// MockStepExecutor is a mock of StepExecutor interface.
type MockStepExecutor struct {
execute.StepExecutor
ctrl *gomock.Controller
recorder *MockStepExecutorMockRecorder
}
// MockStepExecutorMockRecorder is the mock recorder for MockStepExecutor.
type MockStepExecutorMockRecorder struct {
mock *MockStepExecutor
}
// NewMockStepExecutor creates a new mock instance.
func NewMockStepExecutor(ctrl *gomock.Controller) *MockStepExecutor {
mock := &MockStepExecutor{ctrl: ctrl}
mock.recorder = &MockStepExecutorMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockStepExecutor) EXPECT() *MockStepExecutorMockRecorder {
return m.recorder
}
// ISGOMOCK indicates that this struct is a gomock mock.
func (m *MockStepExecutor) ISGOMOCK() struct{} {
return struct{}{}
}
// Cleanup mocks base method.
func (m *MockStepExecutor) Cleanup(arg0 context.Context) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Cleanup", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Cleanup indicates an expected call of Cleanup.
func (mr *MockStepExecutorMockRecorder) Cleanup(arg0 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Cleanup", reflect.TypeOf((*MockStepExecutor)(nil).Cleanup), arg0)
}
// GetCheckpointFunc mocks base method.
func (m *MockStepExecutor) GetCheckpointFunc() func(context.Context, int64) (string, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetCheckpointFunc")
ret0, _ := ret[0].(func(context.Context, int64) (string, error))
return ret0
}
// GetCheckpointFunc indicates an expected call of GetCheckpointFunc.
func (mr *MockStepExecutorMockRecorder) GetCheckpointFunc() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetCheckpointFunc", reflect.TypeOf((*MockStepExecutor)(nil).GetCheckpointFunc))
}
// GetCheckpointUpdateFunc mocks base method.
func (m *MockStepExecutor) GetCheckpointUpdateFunc() func(context.Context, int64, any) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetCheckpointUpdateFunc")
ret0, _ := ret[0].(func(context.Context, int64, any) error)
return ret0
}
// GetCheckpointUpdateFunc indicates an expected call of GetCheckpointUpdateFunc.
func (mr *MockStepExecutorMockRecorder) GetCheckpointUpdateFunc() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetCheckpointUpdateFunc", reflect.TypeOf((*MockStepExecutor)(nil).GetCheckpointUpdateFunc))
}
// GetMeterRecorder mocks base method.
func (m *MockStepExecutor) GetMeterRecorder() *metering.Recorder {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetMeterRecorder")
ret0, _ := ret[0].(*metering.Recorder)
return ret0
}
// GetMeterRecorder indicates an expected call of GetMeterRecorder.
func (mr *MockStepExecutorMockRecorder) GetMeterRecorder() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetMeterRecorder", reflect.TypeOf((*MockStepExecutor)(nil).GetMeterRecorder))
}
// GetResource mocks base method.
func (m *MockStepExecutor) GetResource() *proto.StepResource {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetResource")
ret0, _ := ret[0].(*proto.StepResource)
return ret0
}
// GetResource indicates an expected call of GetResource.
func (mr *MockStepExecutorMockRecorder) GetResource() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetResource", reflect.TypeOf((*MockStepExecutor)(nil).GetResource))
}
// GetStep mocks base method.
func (m *MockStepExecutor) GetStep() proto.Step {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "GetStep")
ret0, _ := ret[0].(proto.Step)
return ret0
}
// GetStep indicates an expected call of GetStep.
func (mr *MockStepExecutorMockRecorder) GetStep() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetStep", reflect.TypeOf((*MockStepExecutor)(nil).GetStep))
}
// Init mocks base method.
func (m *MockStepExecutor) Init(arg0 context.Context) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Init", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Init indicates an expected call of Init.
func (mr *MockStepExecutorMockRecorder) Init(arg0 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Init", reflect.TypeOf((*MockStepExecutor)(nil).Init), arg0)
}
// RealtimeSummary mocks base method.
func (m *MockStepExecutor) RealtimeSummary() *execute.SubtaskSummary {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "RealtimeSummary")
ret0, _ := ret[0].(*execute.SubtaskSummary)
return ret0
}
// RealtimeSummary indicates an expected call of RealtimeSummary.
func (mr *MockStepExecutorMockRecorder) RealtimeSummary() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RealtimeSummary", reflect.TypeOf((*MockStepExecutor)(nil).RealtimeSummary))
}
// ResetSummary mocks base method.
func (m *MockStepExecutor) ResetSummary() {
m.ctrl.T.Helper()
m.ctrl.Call(m, "ResetSummary")
}
// ResetSummary indicates an expected call of ResetSummary.
func (mr *MockStepExecutorMockRecorder) ResetSummary() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ResetSummary", reflect.TypeOf((*MockStepExecutor)(nil).ResetSummary))
}
// ResourceModified mocks base method.
func (m *MockStepExecutor) ResourceModified(arg0 context.Context, arg1 *proto.StepResource) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ResourceModified", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// ResourceModified indicates an expected call of ResourceModified.
func (mr *MockStepExecutorMockRecorder) ResourceModified(arg0, arg1 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ResourceModified", reflect.TypeOf((*MockStepExecutor)(nil).ResourceModified), arg0, arg1)
}
// RunSubtask mocks base method.
func (m *MockStepExecutor) RunSubtask(arg0 context.Context, arg1 *proto.Subtask) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "RunSubtask", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// RunSubtask indicates an expected call of RunSubtask.
func (mr *MockStepExecutorMockRecorder) RunSubtask(arg0, arg1 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RunSubtask", reflect.TypeOf((*MockStepExecutor)(nil).RunSubtask), arg0, arg1)
}
// SetResource mocks base method.
func (m *MockStepExecutor) SetResource(arg0 *proto.StepResource) {
m.ctrl.T.Helper()
m.ctrl.Call(m, "SetResource", arg0)
}
// SetResource indicates an expected call of SetResource.
func (mr *MockStepExecutorMockRecorder) SetResource(arg0 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetResource", reflect.TypeOf((*MockStepExecutor)(nil).SetResource), arg0)
}
// TaskMetaModified mocks base method.
func (m *MockStepExecutor) TaskMetaModified(arg0 context.Context, arg1 []byte) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "TaskMetaModified", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// TaskMetaModified indicates an expected call of TaskMetaModified.
func (mr *MockStepExecutorMockRecorder) TaskMetaModified(arg0, arg1 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TaskMetaModified", reflect.TypeOf((*MockStepExecutor)(nil).TaskMetaModified), arg0, arg1)
}
// restricted mocks base method.
func (m *MockStepExecutor) restricted() {
m.ctrl.T.Helper()
m.ctrl.Call(m, "restricted")
}
// restricted indicates an expected call of restricted.
func (mr *MockStepExecutorMockRecorder) restricted() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "restricted", reflect.TypeOf((*MockStepExecutor)(nil).restricted))
}