mocks

package
v0.17.1 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockApplyLockChecker added in v0.17.0

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

func NewMockApplyLockChecker added in v0.17.0

func NewMockApplyLockChecker(options ...pegomock.Option) *MockApplyLockChecker

func (*MockApplyLockChecker) CheckApplyLock added in v0.17.0

func (mock *MockApplyLockChecker) CheckApplyLock() (locking.ApplyCommandLock, error)

func (*MockApplyLockChecker) FailHandler added in v0.17.0

func (mock *MockApplyLockChecker) FailHandler() pegomock.FailHandler

func (*MockApplyLockChecker) SetFailHandler added in v0.17.0

func (mock *MockApplyLockChecker) SetFailHandler(fh pegomock.FailHandler)

func (*MockApplyLockChecker) VerifyWasCalled added in v0.17.0

func (mock *MockApplyLockChecker) VerifyWasCalled(invocationCountMatcher pegomock.InvocationCountMatcher) *VerifierMockApplyLockChecker

func (*MockApplyLockChecker) VerifyWasCalledEventually added in v0.17.0

func (mock *MockApplyLockChecker) VerifyWasCalledEventually(invocationCountMatcher pegomock.InvocationCountMatcher, timeout time.Duration) *VerifierMockApplyLockChecker

func (*MockApplyLockChecker) VerifyWasCalledInOrder added in v0.17.0

func (mock *MockApplyLockChecker) VerifyWasCalledInOrder(invocationCountMatcher pegomock.InvocationCountMatcher, inOrderContext *pegomock.InOrderContext) *VerifierMockApplyLockChecker

func (*MockApplyLockChecker) VerifyWasCalledOnce added in v0.17.0

func (mock *MockApplyLockChecker) VerifyWasCalledOnce() *VerifierMockApplyLockChecker

type MockApplyLockChecker_CheckApplyLock_OngoingVerification added in v0.17.0

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

func (*MockApplyLockChecker_CheckApplyLock_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockApplyLockChecker_CheckApplyLock_OngoingVerification) GetAllCapturedArguments()

func (*MockApplyLockChecker_CheckApplyLock_OngoingVerification) GetCapturedArguments added in v0.17.0

type MockApplyLocker added in v0.17.0

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

func NewMockApplyLocker added in v0.17.0

func NewMockApplyLocker(options ...pegomock.Option) *MockApplyLocker

func (*MockApplyLocker) CheckApplyLock added in v0.17.0

func (mock *MockApplyLocker) CheckApplyLock() (locking.ApplyCommandLock, error)

func (*MockApplyLocker) FailHandler added in v0.17.0

func (mock *MockApplyLocker) FailHandler() pegomock.FailHandler

func (*MockApplyLocker) LockApply added in v0.17.0

func (mock *MockApplyLocker) LockApply() (locking.ApplyCommandLock, error)

func (*MockApplyLocker) SetFailHandler added in v0.17.0

func (mock *MockApplyLocker) SetFailHandler(fh pegomock.FailHandler)

func (*MockApplyLocker) UnlockApply added in v0.17.0

func (mock *MockApplyLocker) UnlockApply() error

func (*MockApplyLocker) VerifyWasCalled added in v0.17.0

func (mock *MockApplyLocker) VerifyWasCalled(invocationCountMatcher pegomock.InvocationCountMatcher) *VerifierMockApplyLocker

func (*MockApplyLocker) VerifyWasCalledEventually added in v0.17.0

func (mock *MockApplyLocker) VerifyWasCalledEventually(invocationCountMatcher pegomock.InvocationCountMatcher, timeout time.Duration) *VerifierMockApplyLocker

func (*MockApplyLocker) VerifyWasCalledInOrder added in v0.17.0

func (mock *MockApplyLocker) VerifyWasCalledInOrder(invocationCountMatcher pegomock.InvocationCountMatcher, inOrderContext *pegomock.InOrderContext) *VerifierMockApplyLocker

func (*MockApplyLocker) VerifyWasCalledOnce added in v0.17.0

func (mock *MockApplyLocker) VerifyWasCalledOnce() *VerifierMockApplyLocker

type MockApplyLocker_CheckApplyLock_OngoingVerification added in v0.17.0

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

func (*MockApplyLocker_CheckApplyLock_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockApplyLocker_CheckApplyLock_OngoingVerification) GetAllCapturedArguments()

func (*MockApplyLocker_CheckApplyLock_OngoingVerification) GetCapturedArguments added in v0.17.0

func (c *MockApplyLocker_CheckApplyLock_OngoingVerification) GetCapturedArguments()

type MockApplyLocker_LockApply_OngoingVerification added in v0.17.0

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

func (*MockApplyLocker_LockApply_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockApplyLocker_LockApply_OngoingVerification) GetAllCapturedArguments()

func (*MockApplyLocker_LockApply_OngoingVerification) GetCapturedArguments added in v0.17.0

func (c *MockApplyLocker_LockApply_OngoingVerification) GetCapturedArguments()

type MockApplyLocker_UnlockApply_OngoingVerification added in v0.17.0

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

func (*MockApplyLocker_UnlockApply_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockApplyLocker_UnlockApply_OngoingVerification) GetAllCapturedArguments()

func (*MockApplyLocker_UnlockApply_OngoingVerification) GetCapturedArguments added in v0.17.0

func (c *MockApplyLocker_UnlockApply_OngoingVerification) GetCapturedArguments()

type MockBackend

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

func NewMockBackend

func NewMockBackend(options ...pegomock.Option) *MockBackend

func (*MockBackend) CheckCommandLock added in v0.17.0

func (mock *MockBackend) CheckCommandLock(cmdName models.CommandName) (*models.CommandLock, error)

func (*MockBackend) FailHandler added in v0.6.0

func (mock *MockBackend) FailHandler() pegomock.FailHandler

func (*MockBackend) GetLock

func (mock *MockBackend) GetLock(project models.Project, workspace string) (*models.ProjectLock, error)

func (*MockBackend) List

func (mock *MockBackend) List() ([]models.ProjectLock, error)

func (*MockBackend) LockCommand added in v0.17.0

func (mock *MockBackend) LockCommand(cmdName models.CommandName, lockTime time.Time) (*models.CommandLock, error)

func (*MockBackend) SetFailHandler added in v0.6.0

func (mock *MockBackend) SetFailHandler(fh pegomock.FailHandler)

func (*MockBackend) TryLock

func (mock *MockBackend) TryLock(lock models.ProjectLock) (bool, models.ProjectLock, error)

func (*MockBackend) Unlock

func (mock *MockBackend) Unlock(project models.Project, workspace string) (*models.ProjectLock, error)

func (*MockBackend) UnlockByPull

func (mock *MockBackend) UnlockByPull(repoFullName string, pullNum int) ([]models.ProjectLock, error)

func (*MockBackend) UnlockCommand added in v0.17.0

func (mock *MockBackend) UnlockCommand(cmdName models.CommandName) error

func (*MockBackend) VerifyWasCalled

func (mock *MockBackend) VerifyWasCalled(invocationCountMatcher pegomock.InvocationCountMatcher) *VerifierMockBackend

func (*MockBackend) VerifyWasCalledEventually added in v0.4.13

func (mock *MockBackend) VerifyWasCalledEventually(invocationCountMatcher pegomock.InvocationCountMatcher, timeout time.Duration) *VerifierMockBackend

func (*MockBackend) VerifyWasCalledInOrder

func (mock *MockBackend) VerifyWasCalledInOrder(invocationCountMatcher pegomock.InvocationCountMatcher, inOrderContext *pegomock.InOrderContext) *VerifierMockBackend

func (*MockBackend) VerifyWasCalledOnce

func (mock *MockBackend) VerifyWasCalledOnce() *VerifierMockBackend

type MockBackend_CheckCommandLock_OngoingVerification added in v0.17.0

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

func (*MockBackend_CheckCommandLock_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockBackend_CheckCommandLock_OngoingVerification) GetAllCapturedArguments() (_param0 []models.CommandName)

func (*MockBackend_CheckCommandLock_OngoingVerification) GetCapturedArguments added in v0.17.0

type MockBackend_GetLock_OngoingVerification added in v0.8.3

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

func (*MockBackend_GetLock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockBackend_GetLock_OngoingVerification) GetAllCapturedArguments() (_param0 []models.Project, _param1 []string)

func (*MockBackend_GetLock_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockBackend_GetLock_OngoingVerification) GetCapturedArguments() (models.Project, string)

type MockBackend_List_OngoingVerification added in v0.8.3

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

func (*MockBackend_List_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockBackend_List_OngoingVerification) GetAllCapturedArguments()

func (*MockBackend_List_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockBackend_List_OngoingVerification) GetCapturedArguments()

type MockBackend_LockCommand_OngoingVerification added in v0.17.0

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

func (*MockBackend_LockCommand_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockBackend_LockCommand_OngoingVerification) GetAllCapturedArguments() (_param0 []models.CommandName, _param1 []time.Time)

func (*MockBackend_LockCommand_OngoingVerification) GetCapturedArguments added in v0.17.0

type MockBackend_TryLock_OngoingVerification added in v0.8.3

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

func (*MockBackend_TryLock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockBackend_TryLock_OngoingVerification) GetAllCapturedArguments() (_param0 []models.ProjectLock)

func (*MockBackend_TryLock_OngoingVerification) GetCapturedArguments added in v0.8.3

type MockBackend_UnlockByPull_OngoingVerification added in v0.8.3

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

func (*MockBackend_UnlockByPull_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockBackend_UnlockByPull_OngoingVerification) GetAllCapturedArguments() (_param0 []string, _param1 []int)

func (*MockBackend_UnlockByPull_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockBackend_UnlockByPull_OngoingVerification) GetCapturedArguments() (string, int)

type MockBackend_UnlockCommand_OngoingVerification added in v0.17.0

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

func (*MockBackend_UnlockCommand_OngoingVerification) GetAllCapturedArguments added in v0.17.0

func (c *MockBackend_UnlockCommand_OngoingVerification) GetAllCapturedArguments() (_param0 []models.CommandName)

func (*MockBackend_UnlockCommand_OngoingVerification) GetCapturedArguments added in v0.17.0

type MockBackend_Unlock_OngoingVerification added in v0.8.3

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

func (*MockBackend_Unlock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockBackend_Unlock_OngoingVerification) GetAllCapturedArguments() (_param0 []models.Project, _param1 []string)

func (*MockBackend_Unlock_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockBackend_Unlock_OngoingVerification) GetCapturedArguments() (models.Project, string)

type MockLocker

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

func NewMockLocker

func NewMockLocker(options ...pegomock.Option) *MockLocker

func (*MockLocker) FailHandler added in v0.6.0

func (mock *MockLocker) FailHandler() pegomock.FailHandler

func (*MockLocker) GetLock

func (mock *MockLocker) GetLock(key string) (*models.ProjectLock, error)

func (*MockLocker) List

func (mock *MockLocker) List() (map[string]models.ProjectLock, error)

func (*MockLocker) SetFailHandler added in v0.6.0

func (mock *MockLocker) SetFailHandler(fh pegomock.FailHandler)

func (*MockLocker) TryLock

func (mock *MockLocker) TryLock(p models.Project, workspace string, pull models.PullRequest, user models.User) (locking.TryLockResponse, error)

func (*MockLocker) Unlock

func (mock *MockLocker) Unlock(key string) (*models.ProjectLock, error)

func (*MockLocker) UnlockByPull

func (mock *MockLocker) UnlockByPull(repoFullName string, pullNum int) ([]models.ProjectLock, error)

func (*MockLocker) VerifyWasCalled

func (mock *MockLocker) VerifyWasCalled(invocationCountMatcher pegomock.InvocationCountMatcher) *VerifierMockLocker

func (*MockLocker) VerifyWasCalledEventually added in v0.4.13

func (mock *MockLocker) VerifyWasCalledEventually(invocationCountMatcher pegomock.InvocationCountMatcher, timeout time.Duration) *VerifierMockLocker

func (*MockLocker) VerifyWasCalledInOrder

func (mock *MockLocker) VerifyWasCalledInOrder(invocationCountMatcher pegomock.InvocationCountMatcher, inOrderContext *pegomock.InOrderContext) *VerifierMockLocker

func (*MockLocker) VerifyWasCalledOnce

func (mock *MockLocker) VerifyWasCalledOnce() *VerifierMockLocker

type MockLocker_GetLock_OngoingVerification added in v0.8.3

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

func (*MockLocker_GetLock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockLocker_GetLock_OngoingVerification) GetAllCapturedArguments() (_param0 []string)

func (*MockLocker_GetLock_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockLocker_GetLock_OngoingVerification) GetCapturedArguments() string

type MockLocker_List_OngoingVerification added in v0.8.3

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

func (*MockLocker_List_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockLocker_List_OngoingVerification) GetAllCapturedArguments()

func (*MockLocker_List_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockLocker_List_OngoingVerification) GetCapturedArguments()

type MockLocker_TryLock_OngoingVerification added in v0.8.3

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

func (*MockLocker_TryLock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockLocker_TryLock_OngoingVerification) GetAllCapturedArguments() (_param0 []models.Project, _param1 []string, _param2 []models.PullRequest, _param3 []models.User)

func (*MockLocker_TryLock_OngoingVerification) GetCapturedArguments added in v0.8.3

type MockLocker_UnlockByPull_OngoingVerification added in v0.8.3

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

func (*MockLocker_UnlockByPull_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockLocker_UnlockByPull_OngoingVerification) GetAllCapturedArguments() (_param0 []string, _param1 []int)

func (*MockLocker_UnlockByPull_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockLocker_UnlockByPull_OngoingVerification) GetCapturedArguments() (string, int)

type MockLocker_Unlock_OngoingVerification added in v0.8.3

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

func (*MockLocker_Unlock_OngoingVerification) GetAllCapturedArguments added in v0.8.3

func (c *MockLocker_Unlock_OngoingVerification) GetAllCapturedArguments() (_param0 []string)

func (*MockLocker_Unlock_OngoingVerification) GetCapturedArguments added in v0.8.3

func (c *MockLocker_Unlock_OngoingVerification) GetCapturedArguments() string

type VerifierMockApplyLockChecker added in v0.17.0

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

func (*VerifierMockApplyLockChecker) CheckApplyLock added in v0.17.0

type VerifierMockApplyLocker added in v0.17.0

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

func (*VerifierMockApplyLocker) CheckApplyLock added in v0.17.0

func (*VerifierMockApplyLocker) LockApply added in v0.17.0

func (*VerifierMockApplyLocker) UnlockApply added in v0.17.0

type VerifierMockBackend added in v0.8.3

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

func (*VerifierMockBackend) CheckCommandLock added in v0.17.0

func (*VerifierMockBackend) GetLock added in v0.8.3

func (verifier *VerifierMockBackend) GetLock(project models.Project, workspace string) *MockBackend_GetLock_OngoingVerification

func (*VerifierMockBackend) List added in v0.8.3

func (*VerifierMockBackend) LockCommand added in v0.17.0

func (*VerifierMockBackend) TryLock added in v0.8.3

func (*VerifierMockBackend) Unlock added in v0.8.3

func (verifier *VerifierMockBackend) Unlock(project models.Project, workspace string) *MockBackend_Unlock_OngoingVerification

func (*VerifierMockBackend) UnlockByPull added in v0.8.3

func (verifier *VerifierMockBackend) UnlockByPull(repoFullName string, pullNum int) *MockBackend_UnlockByPull_OngoingVerification

func (*VerifierMockBackend) UnlockCommand added in v0.17.0

type VerifierMockLocker added in v0.8.3

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

func (*VerifierMockLocker) GetLock added in v0.8.3

func (*VerifierMockLocker) List added in v0.8.3

func (*VerifierMockLocker) TryLock added in v0.8.3

func (*VerifierMockLocker) Unlock added in v0.8.3

func (*VerifierMockLocker) UnlockByPull added in v0.8.3

func (verifier *VerifierMockLocker) UnlockByPull(repoFullName string, pullNum int) *MockLocker_UnlockByPull_OngoingVerification

Directories

Path Synopsis
Code generated by pegomock.
Code generated by pegomock.

Jump to

Keyboard shortcuts

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