mock_modserver

package
v16.5.0-rc2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 3, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Code generated by MockGen. DO NOT EDIT. Source: ../../../module/modserver/api.go

Generated by this command:

mockgen -typed -source ../../../module/modserver/api.go -destination api.go -package mock_modserver

Package mock_modserver is a generated GoMock package.

Code generated by MockGen. DO NOT EDIT. Source: gitlab.com/gitlab-org/cluster-integration/gitlab-agent/v16/internal/module/modserver (interfaces: RpcApi,AgentRpcApi)

Generated by this command:

mockgen -typed -destination rpc_api.go -package mock_modserver gitlab.com/gitlab-org/cluster-integration/gitlab-agent/v16/internal/module/modserver RpcApi,AgentRpcApi

Package mock_modserver is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AgentMeta added in v16.5.0

func AgentMeta() *entity.AgentMeta

func IncomingAgentCtx

func IncomingAgentCtx(t *testing.T, rpcApi *MockAgentRpcApi) context.Context

Types

type AgentRpcApiAgentInfoCall added in v16.5.0

type AgentRpcApiAgentInfoCall struct {
	*gomock.Call
}

AgentRpcApiAgentInfoCall wrap *gomock.Call

func (*AgentRpcApiAgentInfoCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*AgentRpcApiAgentInfoCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiAgentInfoCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type AgentRpcApiAgentTokenCall added in v16.5.0

type AgentRpcApiAgentTokenCall struct {
	*gomock.Call
}

AgentRpcApiAgentTokenCall wrap *gomock.Call

func (*AgentRpcApiAgentTokenCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*AgentRpcApiAgentTokenCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiAgentTokenCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type AgentRpcApiHandleIoErrorCall added in v16.5.0

type AgentRpcApiHandleIoErrorCall struct {
	*gomock.Call
}

AgentRpcApiHandleIoErrorCall wrap *gomock.Call

func (*AgentRpcApiHandleIoErrorCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*AgentRpcApiHandleIoErrorCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiHandleIoErrorCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type AgentRpcApiHandleProcessingErrorCall added in v16.5.0

type AgentRpcApiHandleProcessingErrorCall struct {
	*gomock.Call
}

AgentRpcApiHandleProcessingErrorCall wrap *gomock.Call

func (*AgentRpcApiHandleProcessingErrorCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*AgentRpcApiHandleProcessingErrorCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiHandleProcessingErrorCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type AgentRpcApiLogCall added in v16.5.0

type AgentRpcApiLogCall struct {
	*gomock.Call
}

AgentRpcApiLogCall wrap *gomock.Call

func (*AgentRpcApiLogCall) Do added in v16.5.0

func (c *AgentRpcApiLogCall) Do(f func() *zap.Logger) *AgentRpcApiLogCall

Do rewrite *gomock.Call.Do

func (*AgentRpcApiLogCall) DoAndReturn added in v16.5.0

func (c *AgentRpcApiLogCall) DoAndReturn(f func() *zap.Logger) *AgentRpcApiLogCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiLogCall) Return added in v16.5.0

func (c *AgentRpcApiLogCall) Return(arg0 *zap.Logger) *AgentRpcApiLogCall

Return rewrite *gomock.Call.Return

type AgentRpcApiPollWithBackoffCall added in v16.5.0

type AgentRpcApiPollWithBackoffCall struct {
	*gomock.Call
}

AgentRpcApiPollWithBackoffCall wrap *gomock.Call

func (*AgentRpcApiPollWithBackoffCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*AgentRpcApiPollWithBackoffCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*AgentRpcApiPollWithBackoffCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type ApiHandleProcessingErrorCall added in v16.5.0

type ApiHandleProcessingErrorCall struct {
	*gomock.Call
}

ApiHandleProcessingErrorCall wrap *gomock.Call

func (*ApiHandleProcessingErrorCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*ApiHandleProcessingErrorCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*ApiHandleProcessingErrorCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type ApiOnGitPushEventCall added in v16.5.0

type ApiOnGitPushEventCall struct {
	*gomock.Call
}

ApiOnGitPushEventCall wrap *gomock.Call

func (*ApiOnGitPushEventCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*ApiOnGitPushEventCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*ApiOnGitPushEventCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type FactoryNameCall added in v16.5.0

type FactoryNameCall struct {
	*gomock.Call
}

FactoryNameCall wrap *gomock.Call

func (*FactoryNameCall) Do added in v16.5.0

func (c *FactoryNameCall) Do(f func() string) *FactoryNameCall

Do rewrite *gomock.Call.Do

func (*FactoryNameCall) DoAndReturn added in v16.5.0

func (c *FactoryNameCall) DoAndReturn(f func() string) *FactoryNameCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*FactoryNameCall) Return added in v16.5.0

func (c *FactoryNameCall) Return(arg0 string) *FactoryNameCall

Return rewrite *gomock.Call.Return

type FactoryNewCall added in v16.5.0

type FactoryNewCall struct {
	*gomock.Call
}

FactoryNewCall wrap *gomock.Call

func (*FactoryNewCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*FactoryNewCall) DoAndReturn added in v16.5.0

func (c *FactoryNewCall) DoAndReturn(f func(*modserver.Config) (modserver.Module, error)) *FactoryNewCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*FactoryNewCall) Return added in v16.5.0

func (c *FactoryNewCall) Return(arg0 modserver.Module, arg1 error) *FactoryNewCall

Return rewrite *gomock.Call.Return

type FactoryStartStopPhaseCall added in v16.5.0

type FactoryStartStopPhaseCall struct {
	*gomock.Call
}

FactoryStartStopPhaseCall wrap *gomock.Call

func (*FactoryStartStopPhaseCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*FactoryStartStopPhaseCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*FactoryStartStopPhaseCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type MockAgentRpcApi

type MockAgentRpcApi struct {
	// contains filtered or unexported fields
}

MockAgentRpcApi is a mock of AgentRpcApi interface.

func NewMockAgentRpcApi

func NewMockAgentRpcApi(ctrl *gomock.Controller) *MockAgentRpcApi

NewMockAgentRpcApi creates a new mock instance.

func NewMockAgentRpcApiWithMockPoller

func NewMockAgentRpcApiWithMockPoller(ctrl *gomock.Controller, pollTimes int) *MockAgentRpcApi

func (*MockAgentRpcApi) AgentInfo

func (m *MockAgentRpcApi) AgentInfo(arg0 context.Context, arg1 *zap.Logger) (*api.AgentInfo, error)

AgentInfo mocks base method.

func (*MockAgentRpcApi) AgentToken

func (m *MockAgentRpcApi) AgentToken() api.AgentToken

AgentToken mocks base method.

func (*MockAgentRpcApi) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockAgentRpcApi) HandleIoError

func (m *MockAgentRpcApi) HandleIoError(arg0 *zap.Logger, arg1 string, arg2 error) error

HandleIoError mocks base method.

func (*MockAgentRpcApi) HandleProcessingError

func (m *MockAgentRpcApi) HandleProcessingError(arg0 *zap.Logger, arg1 int64, arg2 string, arg3 error)

HandleProcessingError mocks base method.

func (*MockAgentRpcApi) Log

func (m *MockAgentRpcApi) Log() *zap.Logger

Log mocks base method.

func (*MockAgentRpcApi) PollWithBackoff

func (m *MockAgentRpcApi) PollWithBackoff(arg0 retry.PollConfig, arg1 retry.PollWithBackoffFunc) error

PollWithBackoff mocks base method.

type MockAgentRpcApiMockRecorder

type MockAgentRpcApiMockRecorder struct {
	// contains filtered or unexported fields
}

MockAgentRpcApiMockRecorder is the mock recorder for MockAgentRpcApi.

func (*MockAgentRpcApiMockRecorder) AgentInfo

func (mr *MockAgentRpcApiMockRecorder) AgentInfo(arg0, arg1 any) *AgentRpcApiAgentInfoCall

AgentInfo indicates an expected call of AgentInfo.

func (*MockAgentRpcApiMockRecorder) AgentToken

AgentToken indicates an expected call of AgentToken.

func (*MockAgentRpcApiMockRecorder) HandleIoError

func (mr *MockAgentRpcApiMockRecorder) HandleIoError(arg0, arg1, arg2 any) *AgentRpcApiHandleIoErrorCall

HandleIoError indicates an expected call of HandleIoError.

func (*MockAgentRpcApiMockRecorder) HandleProcessingError

func (mr *MockAgentRpcApiMockRecorder) HandleProcessingError(arg0, arg1, arg2, arg3 any) *AgentRpcApiHandleProcessingErrorCall

HandleProcessingError indicates an expected call of HandleProcessingError.

func (*MockAgentRpcApiMockRecorder) Log

Log indicates an expected call of Log.

func (*MockAgentRpcApiMockRecorder) PollWithBackoff

func (mr *MockAgentRpcApiMockRecorder) PollWithBackoff(arg0, arg1 any) *AgentRpcApiPollWithBackoffCall

PollWithBackoff indicates an expected call of PollWithBackoff.

type MockApi

type MockApi struct {
	// contains filtered or unexported fields
}

MockApi is a mock of Api interface.

func NewMockApi

func NewMockApi(ctrl *gomock.Controller) *MockApi

NewMockApi creates a new mock instance.

func (*MockApi) EXPECT

func (m *MockApi) EXPECT() *MockApiMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockApi) HandleProcessingError

func (m *MockApi) HandleProcessingError(ctx context.Context, log *zap.Logger, agentId int64, msg string, err error)

HandleProcessingError mocks base method.

func (*MockApi) OnGitPushEvent

func (m *MockApi) OnGitPushEvent(ctx context.Context, cb syncz.EventCallback[*event.GitPushEvent])

OnGitPushEvent mocks base method.

type MockApiMockRecorder

type MockApiMockRecorder struct {
	// contains filtered or unexported fields
}

MockApiMockRecorder is the mock recorder for MockApi.

func (*MockApiMockRecorder) HandleProcessingError

func (mr *MockApiMockRecorder) HandleProcessingError(ctx, log, agentId, msg, err any) *ApiHandleProcessingErrorCall

HandleProcessingError indicates an expected call of HandleProcessingError.

func (*MockApiMockRecorder) OnGitPushEvent

func (mr *MockApiMockRecorder) OnGitPushEvent(ctx, cb any) *ApiOnGitPushEventCall

OnGitPushEvent indicates an expected call of OnGitPushEvent.

type MockFactory added in v16.2.0

type MockFactory struct {
	// contains filtered or unexported fields
}

MockFactory is a mock of Factory interface.

func NewMockFactory added in v16.2.0

func NewMockFactory(ctrl *gomock.Controller) *MockFactory

NewMockFactory creates a new mock instance.

func (*MockFactory) EXPECT added in v16.2.0

func (m *MockFactory) EXPECT() *MockFactoryMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockFactory) Name added in v16.2.0

func (m *MockFactory) Name() string

Name mocks base method.

func (*MockFactory) New added in v16.2.0

func (m *MockFactory) New(arg0 *modserver.Config) (modserver.Module, error)

New mocks base method.

func (*MockFactory) StartStopPhase added in v16.2.0

func (m *MockFactory) StartStopPhase() modshared.ModuleStartStopPhase

StartStopPhase mocks base method.

type MockFactoryMockRecorder added in v16.2.0

type MockFactoryMockRecorder struct {
	// contains filtered or unexported fields
}

MockFactoryMockRecorder is the mock recorder for MockFactory.

func (*MockFactoryMockRecorder) Name added in v16.2.0

Name indicates an expected call of Name.

func (*MockFactoryMockRecorder) New added in v16.2.0

New indicates an expected call of New.

func (*MockFactoryMockRecorder) StartStopPhase added in v16.2.0

func (mr *MockFactoryMockRecorder) StartStopPhase() *FactoryStartStopPhaseCall

StartStopPhase indicates an expected call of StartStopPhase.

type MockModule added in v16.2.0

type MockModule struct {
	// contains filtered or unexported fields
}

MockModule is a mock of Module interface.

func NewMockModule added in v16.2.0

func NewMockModule(ctrl *gomock.Controller) *MockModule

NewMockModule creates a new mock instance.

func (*MockModule) EXPECT added in v16.2.0

func (m *MockModule) EXPECT() *MockModuleMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockModule) Name added in v16.2.0

func (m *MockModule) Name() string

Name mocks base method.

func (*MockModule) Run added in v16.2.0

func (m *MockModule) Run(arg0 context.Context) error

Run mocks base method.

type MockModuleMockRecorder added in v16.2.0

type MockModuleMockRecorder struct {
	// contains filtered or unexported fields
}

MockModuleMockRecorder is the mock recorder for MockModule.

func (*MockModuleMockRecorder) Name added in v16.2.0

Name indicates an expected call of Name.

func (*MockModuleMockRecorder) Run added in v16.2.0

func (mr *MockModuleMockRecorder) Run(arg0 any) *ModuleRunCall

Run indicates an expected call of Run.

type MockRpcApi

type MockRpcApi struct {
	// contains filtered or unexported fields
}

MockRpcApi is a mock of RpcApi interface.

func NewMockRpcApi

func NewMockRpcApi(ctrl *gomock.Controller) *MockRpcApi

NewMockRpcApi creates a new mock instance.

func (*MockRpcApi) EXPECT

func (m *MockRpcApi) EXPECT() *MockRpcApiMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockRpcApi) HandleIoError

func (m *MockRpcApi) HandleIoError(arg0 *zap.Logger, arg1 string, arg2 error) error

HandleIoError mocks base method.

func (*MockRpcApi) HandleProcessingError

func (m *MockRpcApi) HandleProcessingError(arg0 *zap.Logger, arg1 int64, arg2 string, arg3 error)

HandleProcessingError mocks base method.

func (*MockRpcApi) Log

func (m *MockRpcApi) Log() *zap.Logger

Log mocks base method.

func (*MockRpcApi) PollWithBackoff

func (m *MockRpcApi) PollWithBackoff(arg0 retry.PollConfig, arg1 retry.PollWithBackoffFunc) error

PollWithBackoff mocks base method.

type MockRpcApiMockRecorder

type MockRpcApiMockRecorder struct {
	// contains filtered or unexported fields
}

MockRpcApiMockRecorder is the mock recorder for MockRpcApi.

func (*MockRpcApiMockRecorder) HandleIoError

func (mr *MockRpcApiMockRecorder) HandleIoError(arg0, arg1, arg2 any) *RpcApiHandleIoErrorCall

HandleIoError indicates an expected call of HandleIoError.

func (*MockRpcApiMockRecorder) HandleProcessingError

func (mr *MockRpcApiMockRecorder) HandleProcessingError(arg0, arg1, arg2, arg3 any) *RpcApiHandleProcessingErrorCall

HandleProcessingError indicates an expected call of HandleProcessingError.

func (*MockRpcApiMockRecorder) Log

Log indicates an expected call of Log.

func (*MockRpcApiMockRecorder) PollWithBackoff

func (mr *MockRpcApiMockRecorder) PollWithBackoff(arg0, arg1 any) *RpcApiPollWithBackoffCall

PollWithBackoff indicates an expected call of PollWithBackoff.

type ModuleNameCall added in v16.5.0

type ModuleNameCall struct {
	*gomock.Call
}

ModuleNameCall wrap *gomock.Call

func (*ModuleNameCall) Do added in v16.5.0

func (c *ModuleNameCall) Do(f func() string) *ModuleNameCall

Do rewrite *gomock.Call.Do

func (*ModuleNameCall) DoAndReturn added in v16.5.0

func (c *ModuleNameCall) DoAndReturn(f func() string) *ModuleNameCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*ModuleNameCall) Return added in v16.5.0

func (c *ModuleNameCall) Return(arg0 string) *ModuleNameCall

Return rewrite *gomock.Call.Return

type ModuleRunCall added in v16.5.0

type ModuleRunCall struct {
	*gomock.Call
}

ModuleRunCall wrap *gomock.Call

func (*ModuleRunCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*ModuleRunCall) DoAndReturn added in v16.5.0

func (c *ModuleRunCall) DoAndReturn(f func(context.Context) error) *ModuleRunCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*ModuleRunCall) Return added in v16.5.0

func (c *ModuleRunCall) Return(arg0 error) *ModuleRunCall

Return rewrite *gomock.Call.Return

type RpcApiHandleIoErrorCall added in v16.5.0

type RpcApiHandleIoErrorCall struct {
	*gomock.Call
}

RpcApiHandleIoErrorCall wrap *gomock.Call

func (*RpcApiHandleIoErrorCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*RpcApiHandleIoErrorCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*RpcApiHandleIoErrorCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type RpcApiHandleProcessingErrorCall added in v16.5.0

type RpcApiHandleProcessingErrorCall struct {
	*gomock.Call
}

RpcApiHandleProcessingErrorCall wrap *gomock.Call

func (*RpcApiHandleProcessingErrorCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*RpcApiHandleProcessingErrorCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*RpcApiHandleProcessingErrorCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

type RpcApiLogCall added in v16.5.0

type RpcApiLogCall struct {
	*gomock.Call
}

RpcApiLogCall wrap *gomock.Call

func (*RpcApiLogCall) Do added in v16.5.0

func (c *RpcApiLogCall) Do(f func() *zap.Logger) *RpcApiLogCall

Do rewrite *gomock.Call.Do

func (*RpcApiLogCall) DoAndReturn added in v16.5.0

func (c *RpcApiLogCall) DoAndReturn(f func() *zap.Logger) *RpcApiLogCall

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*RpcApiLogCall) Return added in v16.5.0

func (c *RpcApiLogCall) Return(arg0 *zap.Logger) *RpcApiLogCall

Return rewrite *gomock.Call.Return

type RpcApiPollWithBackoffCall added in v16.5.0

type RpcApiPollWithBackoffCall struct {
	*gomock.Call
}

RpcApiPollWithBackoffCall wrap *gomock.Call

func (*RpcApiPollWithBackoffCall) Do added in v16.5.0

Do rewrite *gomock.Call.Do

func (*RpcApiPollWithBackoffCall) DoAndReturn added in v16.5.0

DoAndReturn rewrite *gomock.Call.DoAndReturn

func (*RpcApiPollWithBackoffCall) Return added in v16.5.0

Return rewrite *gomock.Call.Return

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL