fakes

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: May 17, 2019 License: Apache-2.0 Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GitCommitCacheMock

type GitCommitCacheMock struct {
	// AddIndexerFunc mocks the AddIndexer method.
	AddIndexerFunc func(indexName string, indexer v1.GitCommitIndexer)

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string) (*v1a.GitCommit, error)

	// GetByIndexFunc mocks the GetByIndex method.
	GetByIndexFunc func(indexName string, key string) ([]*v1a.GitCommit, error)

	// ListFunc mocks the List method.
	ListFunc func(namespace string, selector labels.Selector) ([]*v1a.GitCommit, error)
	// contains filtered or unexported fields
}

GitCommitCacheMock is a mock implementation of GitCommitCache.

    func TestSomethingThatUsesGitCommitCache(t *testing.T) {

        // make and configure a mocked GitCommitCache
        mockedGitCommitCache := &GitCommitCacheMock{
            AddIndexerFunc: func(indexName string, indexer v1.GitCommitIndexer)  {
	               panic("mock out the AddIndexer method")
            },
            GetFunc: func(namespace string, name string) (*v1a.GitCommit, error) {
	               panic("mock out the Get method")
            },
            GetByIndexFunc: func(indexName string, key string) ([]*v1a.GitCommit, error) {
	               panic("mock out the GetByIndex method")
            },
            ListFunc: func(namespace string, selector labels.Selector) ([]*v1a.GitCommit, error) {
	               panic("mock out the List method")
            },
        }

        // use mockedGitCommitCache in code that requires GitCommitCache
        // and then make assertions.

    }

func (*GitCommitCacheMock) AddIndexer

func (mock *GitCommitCacheMock) AddIndexer(indexName string, indexer v1.GitCommitIndexer)

AddIndexer calls AddIndexerFunc.

func (*GitCommitCacheMock) AddIndexerCalls

func (mock *GitCommitCacheMock) AddIndexerCalls() []struct {
	IndexName string
	Indexer   v1.GitCommitIndexer
}

AddIndexerCalls gets all the calls that were made to AddIndexer. Check the length with:

len(mockedGitCommitCache.AddIndexerCalls())

func (*GitCommitCacheMock) Get

func (mock *GitCommitCacheMock) Get(namespace string, name string) (*v1a.GitCommit, error)

Get calls GetFunc.

func (*GitCommitCacheMock) GetByIndex

func (mock *GitCommitCacheMock) GetByIndex(indexName string, key string) ([]*v1a.GitCommit, error)

GetByIndex calls GetByIndexFunc.

func (*GitCommitCacheMock) GetByIndexCalls

func (mock *GitCommitCacheMock) GetByIndexCalls() []struct {
	IndexName string
	Key       string
}

GetByIndexCalls gets all the calls that were made to GetByIndex. Check the length with:

len(mockedGitCommitCache.GetByIndexCalls())

func (*GitCommitCacheMock) GetCalls

func (mock *GitCommitCacheMock) GetCalls() []struct {
	Namespace string
	Name      string
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitCommitCache.GetCalls())

func (*GitCommitCacheMock) List

func (mock *GitCommitCacheMock) List(namespace string, selector labels.Selector) ([]*v1a.GitCommit, error)

List calls ListFunc.

func (*GitCommitCacheMock) ListCalls

func (mock *GitCommitCacheMock) ListCalls() []struct {
	Namespace string
	Selector  labels.Selector
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitCommitCache.ListCalls())

type GitCommitClientMock

type GitCommitClientMock struct {
	// CreateFunc mocks the Create method.
	CreateFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// DeleteFunc mocks the Delete method.
	DeleteFunc func(namespace string, name string, options *v1b.DeleteOptions) error

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error)

	// ListFunc mocks the List method.
	ListFunc func(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error)

	// PatchFunc mocks the Patch method.
	PatchFunc func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error)

	// UpdateFunc mocks the Update method.
	UpdateFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// UpdateStatusFunc mocks the UpdateStatus method.
	UpdateStatusFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// WatchFunc mocks the Watch method.
	WatchFunc func(namespace string, opts v1b.ListOptions) (watch.Interface, error)
	// contains filtered or unexported fields
}

GitCommitClientMock is a mock implementation of GitCommitClient.

    func TestSomethingThatUsesGitCommitClient(t *testing.T) {

        // make and configure a mocked GitCommitClient
        mockedGitCommitClient := &GitCommitClientMock{
            CreateFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the Create method")
            },
            DeleteFunc: func(namespace string, name string, options *v1b.DeleteOptions) error {
	               panic("mock out the Delete method")
            },
            GetFunc: func(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error) {
	               panic("mock out the Get method")
            },
            ListFunc: func(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error) {
	               panic("mock out the List method")
            },
            PatchFunc: func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error) {
	               panic("mock out the Patch method")
            },
            UpdateFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the Update method")
            },
            UpdateStatusFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the UpdateStatus method")
            },
            WatchFunc: func(namespace string, opts v1b.ListOptions) (watch.Interface, error) {
	               panic("mock out the Watch method")
            },
        }

        // use mockedGitCommitClient in code that requires GitCommitClient
        // and then make assertions.

    }

func (*GitCommitClientMock) Create

func (mock *GitCommitClientMock) Create(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

Create calls CreateFunc.

func (*GitCommitClientMock) CreateCalls

func (mock *GitCommitClientMock) CreateCalls() []struct {
	In1 *v1a.GitCommit
}

CreateCalls gets all the calls that were made to Create. Check the length with:

len(mockedGitCommitClient.CreateCalls())

func (*GitCommitClientMock) Delete

func (mock *GitCommitClientMock) Delete(namespace string, name string, options *v1b.DeleteOptions) error

Delete calls DeleteFunc.

func (*GitCommitClientMock) DeleteCalls

func (mock *GitCommitClientMock) DeleteCalls() []struct {
	Namespace string
	Name      string
	Options   *v1b.DeleteOptions
}

DeleteCalls gets all the calls that were made to Delete. Check the length with:

len(mockedGitCommitClient.DeleteCalls())

func (*GitCommitClientMock) Get

func (mock *GitCommitClientMock) Get(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error)

Get calls GetFunc.

func (*GitCommitClientMock) GetCalls

func (mock *GitCommitClientMock) GetCalls() []struct {
	Namespace string
	Name      string
	Options   v1b.GetOptions
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitCommitClient.GetCalls())

func (*GitCommitClientMock) List

func (mock *GitCommitClientMock) List(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error)

List calls ListFunc.

func (*GitCommitClientMock) ListCalls

func (mock *GitCommitClientMock) ListCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitCommitClient.ListCalls())

func (*GitCommitClientMock) Patch

func (mock *GitCommitClientMock) Patch(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error)

Patch calls PatchFunc.

func (*GitCommitClientMock) PatchCalls

func (mock *GitCommitClientMock) PatchCalls() []struct {
	Namespace    string
	Name         string
	Pt           types.PatchType
	Data         []byte
	Subresources []string
}

PatchCalls gets all the calls that were made to Patch. Check the length with:

len(mockedGitCommitClient.PatchCalls())

func (*GitCommitClientMock) Update

func (mock *GitCommitClientMock) Update(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

Update calls UpdateFunc.

func (*GitCommitClientMock) UpdateCalls

func (mock *GitCommitClientMock) UpdateCalls() []struct {
	In1 *v1a.GitCommit
}

UpdateCalls gets all the calls that were made to Update. Check the length with:

len(mockedGitCommitClient.UpdateCalls())

func (*GitCommitClientMock) UpdateStatus

func (mock *GitCommitClientMock) UpdateStatus(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

UpdateStatus calls UpdateStatusFunc.

func (*GitCommitClientMock) UpdateStatusCalls

func (mock *GitCommitClientMock) UpdateStatusCalls() []struct {
	In1 *v1a.GitCommit
}

UpdateStatusCalls gets all the calls that were made to UpdateStatus. Check the length with:

len(mockedGitCommitClient.UpdateStatusCalls())

func (*GitCommitClientMock) Watch

func (mock *GitCommitClientMock) Watch(namespace string, opts v1b.ListOptions) (watch.Interface, error)

Watch calls WatchFunc.

func (*GitCommitClientMock) WatchCalls

func (mock *GitCommitClientMock) WatchCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

WatchCalls gets all the calls that were made to Watch. Check the length with:

len(mockedGitCommitClient.WatchCalls())

type GitCommitControllerMock

type GitCommitControllerMock struct {
	// AddGenericHandlerFunc mocks the AddGenericHandler method.
	AddGenericHandlerFunc func(ctx context.Context, name string, handler generic.Handler)

	// AddGenericRemoveHandlerFunc mocks the AddGenericRemoveHandler method.
	AddGenericRemoveHandlerFunc func(ctx context.Context, name string, handler generic.Handler)

	// CacheFunc mocks the Cache method.
	CacheFunc func() v1.GitCommitCache

	// CreateFunc mocks the Create method.
	CreateFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// DeleteFunc mocks the Delete method.
	DeleteFunc func(namespace string, name string, options *v1b.DeleteOptions) error

	// EnqueueFunc mocks the Enqueue method.
	EnqueueFunc func(namespace string, name string)

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error)

	// GroupVersionKindFunc mocks the GroupVersionKind method.
	GroupVersionKindFunc func() schema.GroupVersionKind

	// InformerFunc mocks the Informer method.
	InformerFunc func() cache.SharedIndexInformer

	// ListFunc mocks the List method.
	ListFunc func(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error)

	// OnChangeFunc mocks the OnChange method.
	OnChangeFunc func(ctx context.Context, name string, sync v1.GitCommitHandler)

	// OnRemoveFunc mocks the OnRemove method.
	OnRemoveFunc func(ctx context.Context, name string, sync v1.GitCommitHandler)

	// PatchFunc mocks the Patch method.
	PatchFunc func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error)

	// UpdateFunc mocks the Update method.
	UpdateFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// UpdateStatusFunc mocks the UpdateStatus method.
	UpdateStatusFunc func(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

	// UpdaterFunc mocks the Updater method.
	UpdaterFunc func() generic.Updater

	// WatchFunc mocks the Watch method.
	WatchFunc func(namespace string, opts v1b.ListOptions) (watch.Interface, error)
	// contains filtered or unexported fields
}

GitCommitControllerMock is a mock implementation of GitCommitController.

    func TestSomethingThatUsesGitCommitController(t *testing.T) {

        // make and configure a mocked GitCommitController
        mockedGitCommitController := &GitCommitControllerMock{
            AddGenericHandlerFunc: func(ctx context.Context, name string, handler generic.Handler)  {
	               panic("mock out the AddGenericHandler method")
            },
            AddGenericRemoveHandlerFunc: func(ctx context.Context, name string, handler generic.Handler)  {
	               panic("mock out the AddGenericRemoveHandler method")
            },
            CacheFunc: func() v1.GitCommitCache {
	               panic("mock out the Cache method")
            },
            CreateFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the Create method")
            },
            DeleteFunc: func(namespace string, name string, options *v1b.DeleteOptions) error {
	               panic("mock out the Delete method")
            },
            EnqueueFunc: func(namespace string, name string)  {
	               panic("mock out the Enqueue method")
            },
            GetFunc: func(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error) {
	               panic("mock out the Get method")
            },
            GroupVersionKindFunc: func() schema.GroupVersionKind {
	               panic("mock out the GroupVersionKind method")
            },
            InformerFunc: func() cache.SharedIndexInformer {
	               panic("mock out the Informer method")
            },
            ListFunc: func(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error) {
	               panic("mock out the List method")
            },
            OnChangeFunc: func(ctx context.Context, name string, sync v1.GitCommitHandler)  {
	               panic("mock out the OnChange method")
            },
            OnRemoveFunc: func(ctx context.Context, name string, sync v1.GitCommitHandler)  {
	               panic("mock out the OnRemove method")
            },
            PatchFunc: func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error) {
	               panic("mock out the Patch method")
            },
            UpdateFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the Update method")
            },
            UpdateStatusFunc: func(in1 *v1a.GitCommit) (*v1a.GitCommit, error) {
	               panic("mock out the UpdateStatus method")
            },
            UpdaterFunc: func() generic.Updater {
	               panic("mock out the Updater method")
            },
            WatchFunc: func(namespace string, opts v1b.ListOptions) (watch.Interface, error) {
	               panic("mock out the Watch method")
            },
        }

        // use mockedGitCommitController in code that requires GitCommitController
        // and then make assertions.

    }

func (*GitCommitControllerMock) AddGenericHandler

func (mock *GitCommitControllerMock) AddGenericHandler(ctx context.Context, name string, handler generic.Handler)

AddGenericHandler calls AddGenericHandlerFunc.

func (*GitCommitControllerMock) AddGenericHandlerCalls

func (mock *GitCommitControllerMock) AddGenericHandlerCalls() []struct {
	Ctx     context.Context
	Name    string
	Handler generic.Handler
}

AddGenericHandlerCalls gets all the calls that were made to AddGenericHandler. Check the length with:

len(mockedGitCommitController.AddGenericHandlerCalls())

func (*GitCommitControllerMock) AddGenericRemoveHandler

func (mock *GitCommitControllerMock) AddGenericRemoveHandler(ctx context.Context, name string, handler generic.Handler)

AddGenericRemoveHandler calls AddGenericRemoveHandlerFunc.

func (*GitCommitControllerMock) AddGenericRemoveHandlerCalls

func (mock *GitCommitControllerMock) AddGenericRemoveHandlerCalls() []struct {
	Ctx     context.Context
	Name    string
	Handler generic.Handler
}

AddGenericRemoveHandlerCalls gets all the calls that were made to AddGenericRemoveHandler. Check the length with:

len(mockedGitCommitController.AddGenericRemoveHandlerCalls())

func (*GitCommitControllerMock) Cache

Cache calls CacheFunc.

func (*GitCommitControllerMock) CacheCalls

func (mock *GitCommitControllerMock) CacheCalls() []struct {
}

CacheCalls gets all the calls that were made to Cache. Check the length with:

len(mockedGitCommitController.CacheCalls())

func (*GitCommitControllerMock) Create

func (mock *GitCommitControllerMock) Create(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

Create calls CreateFunc.

func (*GitCommitControllerMock) CreateCalls

func (mock *GitCommitControllerMock) CreateCalls() []struct {
	In1 *v1a.GitCommit
}

CreateCalls gets all the calls that were made to Create. Check the length with:

len(mockedGitCommitController.CreateCalls())

func (*GitCommitControllerMock) Delete

func (mock *GitCommitControllerMock) Delete(namespace string, name string, options *v1b.DeleteOptions) error

Delete calls DeleteFunc.

func (*GitCommitControllerMock) DeleteCalls

func (mock *GitCommitControllerMock) DeleteCalls() []struct {
	Namespace string
	Name      string
	Options   *v1b.DeleteOptions
}

DeleteCalls gets all the calls that were made to Delete. Check the length with:

len(mockedGitCommitController.DeleteCalls())

func (*GitCommitControllerMock) Enqueue

func (mock *GitCommitControllerMock) Enqueue(namespace string, name string)

Enqueue calls EnqueueFunc.

func (*GitCommitControllerMock) EnqueueCalls

func (mock *GitCommitControllerMock) EnqueueCalls() []struct {
	Namespace string
	Name      string
}

EnqueueCalls gets all the calls that were made to Enqueue. Check the length with:

len(mockedGitCommitController.EnqueueCalls())

func (*GitCommitControllerMock) Get

func (mock *GitCommitControllerMock) Get(namespace string, name string, options v1b.GetOptions) (*v1a.GitCommit, error)

Get calls GetFunc.

func (*GitCommitControllerMock) GetCalls

func (mock *GitCommitControllerMock) GetCalls() []struct {
	Namespace string
	Name      string
	Options   v1b.GetOptions
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitCommitController.GetCalls())

func (*GitCommitControllerMock) GroupVersionKind

func (mock *GitCommitControllerMock) GroupVersionKind() schema.GroupVersionKind

GroupVersionKind calls GroupVersionKindFunc.

func (*GitCommitControllerMock) GroupVersionKindCalls

func (mock *GitCommitControllerMock) GroupVersionKindCalls() []struct {
}

GroupVersionKindCalls gets all the calls that were made to GroupVersionKind. Check the length with:

len(mockedGitCommitController.GroupVersionKindCalls())

func (*GitCommitControllerMock) Informer

Informer calls InformerFunc.

func (*GitCommitControllerMock) InformerCalls

func (mock *GitCommitControllerMock) InformerCalls() []struct {
}

InformerCalls gets all the calls that were made to Informer. Check the length with:

len(mockedGitCommitController.InformerCalls())

func (*GitCommitControllerMock) List

func (mock *GitCommitControllerMock) List(namespace string, opts v1b.ListOptions) (*v1a.GitCommitList, error)

List calls ListFunc.

func (*GitCommitControllerMock) ListCalls

func (mock *GitCommitControllerMock) ListCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitCommitController.ListCalls())

func (*GitCommitControllerMock) OnChange

func (mock *GitCommitControllerMock) OnChange(ctx context.Context, name string, sync v1.GitCommitHandler)

OnChange calls OnChangeFunc.

func (*GitCommitControllerMock) OnChangeCalls

func (mock *GitCommitControllerMock) OnChangeCalls() []struct {
	Ctx  context.Context
	Name string
	Sync v1.GitCommitHandler
}

OnChangeCalls gets all the calls that were made to OnChange. Check the length with:

len(mockedGitCommitController.OnChangeCalls())

func (*GitCommitControllerMock) OnRemove

func (mock *GitCommitControllerMock) OnRemove(ctx context.Context, name string, sync v1.GitCommitHandler)

OnRemove calls OnRemoveFunc.

func (*GitCommitControllerMock) OnRemoveCalls

func (mock *GitCommitControllerMock) OnRemoveCalls() []struct {
	Ctx  context.Context
	Name string
	Sync v1.GitCommitHandler
}

OnRemoveCalls gets all the calls that were made to OnRemove. Check the length with:

len(mockedGitCommitController.OnRemoveCalls())

func (*GitCommitControllerMock) Patch

func (mock *GitCommitControllerMock) Patch(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitCommit, error)

Patch calls PatchFunc.

func (*GitCommitControllerMock) PatchCalls

func (mock *GitCommitControllerMock) PatchCalls() []struct {
	Namespace    string
	Name         string
	Pt           types.PatchType
	Data         []byte
	Subresources []string
}

PatchCalls gets all the calls that were made to Patch. Check the length with:

len(mockedGitCommitController.PatchCalls())

func (*GitCommitControllerMock) Update

func (mock *GitCommitControllerMock) Update(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

Update calls UpdateFunc.

func (*GitCommitControllerMock) UpdateCalls

func (mock *GitCommitControllerMock) UpdateCalls() []struct {
	In1 *v1a.GitCommit
}

UpdateCalls gets all the calls that were made to Update. Check the length with:

len(mockedGitCommitController.UpdateCalls())

func (*GitCommitControllerMock) UpdateStatus

func (mock *GitCommitControllerMock) UpdateStatus(in1 *v1a.GitCommit) (*v1a.GitCommit, error)

UpdateStatus calls UpdateStatusFunc.

func (*GitCommitControllerMock) UpdateStatusCalls

func (mock *GitCommitControllerMock) UpdateStatusCalls() []struct {
	In1 *v1a.GitCommit
}

UpdateStatusCalls gets all the calls that were made to UpdateStatus. Check the length with:

len(mockedGitCommitController.UpdateStatusCalls())

func (*GitCommitControllerMock) Updater

func (mock *GitCommitControllerMock) Updater() generic.Updater

Updater calls UpdaterFunc.

func (*GitCommitControllerMock) UpdaterCalls

func (mock *GitCommitControllerMock) UpdaterCalls() []struct {
}

UpdaterCalls gets all the calls that were made to Updater. Check the length with:

len(mockedGitCommitController.UpdaterCalls())

func (*GitCommitControllerMock) Watch

func (mock *GitCommitControllerMock) Watch(namespace string, opts v1b.ListOptions) (watch.Interface, error)

Watch calls WatchFunc.

func (*GitCommitControllerMock) WatchCalls

func (mock *GitCommitControllerMock) WatchCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

WatchCalls gets all the calls that were made to Watch. Check the length with:

len(mockedGitCommitController.WatchCalls())

type GitWatcherCacheMock

type GitWatcherCacheMock struct {
	// AddIndexerFunc mocks the AddIndexer method.
	AddIndexerFunc func(indexName string, indexer v1.GitWatcherIndexer)

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string) (*v1a.GitWatcher, error)

	// GetByIndexFunc mocks the GetByIndex method.
	GetByIndexFunc func(indexName string, key string) ([]*v1a.GitWatcher, error)

	// ListFunc mocks the List method.
	ListFunc func(namespace string, selector labels.Selector) ([]*v1a.GitWatcher, error)
	// contains filtered or unexported fields
}

GitWatcherCacheMock is a mock implementation of GitWatcherCache.

    func TestSomethingThatUsesGitWatcherCache(t *testing.T) {

        // make and configure a mocked GitWatcherCache
        mockedGitWatcherCache := &GitWatcherCacheMock{
            AddIndexerFunc: func(indexName string, indexer v1.GitWatcherIndexer)  {
	               panic("mock out the AddIndexer method")
            },
            GetFunc: func(namespace string, name string) (*v1a.GitWatcher, error) {
	               panic("mock out the Get method")
            },
            GetByIndexFunc: func(indexName string, key string) ([]*v1a.GitWatcher, error) {
	               panic("mock out the GetByIndex method")
            },
            ListFunc: func(namespace string, selector labels.Selector) ([]*v1a.GitWatcher, error) {
	               panic("mock out the List method")
            },
        }

        // use mockedGitWatcherCache in code that requires GitWatcherCache
        // and then make assertions.

    }

func (*GitWatcherCacheMock) AddIndexer

func (mock *GitWatcherCacheMock) AddIndexer(indexName string, indexer v1.GitWatcherIndexer)

AddIndexer calls AddIndexerFunc.

func (*GitWatcherCacheMock) AddIndexerCalls

func (mock *GitWatcherCacheMock) AddIndexerCalls() []struct {
	IndexName string
	Indexer   v1.GitWatcherIndexer
}

AddIndexerCalls gets all the calls that were made to AddIndexer. Check the length with:

len(mockedGitWatcherCache.AddIndexerCalls())

func (*GitWatcherCacheMock) Get

func (mock *GitWatcherCacheMock) Get(namespace string, name string) (*v1a.GitWatcher, error)

Get calls GetFunc.

func (*GitWatcherCacheMock) GetByIndex

func (mock *GitWatcherCacheMock) GetByIndex(indexName string, key string) ([]*v1a.GitWatcher, error)

GetByIndex calls GetByIndexFunc.

func (*GitWatcherCacheMock) GetByIndexCalls

func (mock *GitWatcherCacheMock) GetByIndexCalls() []struct {
	IndexName string
	Key       string
}

GetByIndexCalls gets all the calls that were made to GetByIndex. Check the length with:

len(mockedGitWatcherCache.GetByIndexCalls())

func (*GitWatcherCacheMock) GetCalls

func (mock *GitWatcherCacheMock) GetCalls() []struct {
	Namespace string
	Name      string
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitWatcherCache.GetCalls())

func (*GitWatcherCacheMock) List

func (mock *GitWatcherCacheMock) List(namespace string, selector labels.Selector) ([]*v1a.GitWatcher, error)

List calls ListFunc.

func (*GitWatcherCacheMock) ListCalls

func (mock *GitWatcherCacheMock) ListCalls() []struct {
	Namespace string
	Selector  labels.Selector
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitWatcherCache.ListCalls())

type GitWatcherClientMock

type GitWatcherClientMock struct {
	// CreateFunc mocks the Create method.
	CreateFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// DeleteFunc mocks the Delete method.
	DeleteFunc func(namespace string, name string, options *v1b.DeleteOptions) error

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error)

	// ListFunc mocks the List method.
	ListFunc func(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error)

	// PatchFunc mocks the Patch method.
	PatchFunc func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error)

	// UpdateFunc mocks the Update method.
	UpdateFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// UpdateStatusFunc mocks the UpdateStatus method.
	UpdateStatusFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// WatchFunc mocks the Watch method.
	WatchFunc func(namespace string, opts v1b.ListOptions) (watch.Interface, error)
	// contains filtered or unexported fields
}

GitWatcherClientMock is a mock implementation of GitWatcherClient.

    func TestSomethingThatUsesGitWatcherClient(t *testing.T) {

        // make and configure a mocked GitWatcherClient
        mockedGitWatcherClient := &GitWatcherClientMock{
            CreateFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the Create method")
            },
            DeleteFunc: func(namespace string, name string, options *v1b.DeleteOptions) error {
	               panic("mock out the Delete method")
            },
            GetFunc: func(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error) {
	               panic("mock out the Get method")
            },
            ListFunc: func(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error) {
	               panic("mock out the List method")
            },
            PatchFunc: func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error) {
	               panic("mock out the Patch method")
            },
            UpdateFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the Update method")
            },
            UpdateStatusFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the UpdateStatus method")
            },
            WatchFunc: func(namespace string, opts v1b.ListOptions) (watch.Interface, error) {
	               panic("mock out the Watch method")
            },
        }

        // use mockedGitWatcherClient in code that requires GitWatcherClient
        // and then make assertions.

    }

func (*GitWatcherClientMock) Create

func (mock *GitWatcherClientMock) Create(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

Create calls CreateFunc.

func (*GitWatcherClientMock) CreateCalls

func (mock *GitWatcherClientMock) CreateCalls() []struct {
	In1 *v1a.GitWatcher
}

CreateCalls gets all the calls that were made to Create. Check the length with:

len(mockedGitWatcherClient.CreateCalls())

func (*GitWatcherClientMock) Delete

func (mock *GitWatcherClientMock) Delete(namespace string, name string, options *v1b.DeleteOptions) error

Delete calls DeleteFunc.

func (*GitWatcherClientMock) DeleteCalls

func (mock *GitWatcherClientMock) DeleteCalls() []struct {
	Namespace string
	Name      string
	Options   *v1b.DeleteOptions
}

DeleteCalls gets all the calls that were made to Delete. Check the length with:

len(mockedGitWatcherClient.DeleteCalls())

func (*GitWatcherClientMock) Get

func (mock *GitWatcherClientMock) Get(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error)

Get calls GetFunc.

func (*GitWatcherClientMock) GetCalls

func (mock *GitWatcherClientMock) GetCalls() []struct {
	Namespace string
	Name      string
	Options   v1b.GetOptions
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitWatcherClient.GetCalls())

func (*GitWatcherClientMock) List

func (mock *GitWatcherClientMock) List(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error)

List calls ListFunc.

func (*GitWatcherClientMock) ListCalls

func (mock *GitWatcherClientMock) ListCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitWatcherClient.ListCalls())

func (*GitWatcherClientMock) Patch

func (mock *GitWatcherClientMock) Patch(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error)

Patch calls PatchFunc.

func (*GitWatcherClientMock) PatchCalls

func (mock *GitWatcherClientMock) PatchCalls() []struct {
	Namespace    string
	Name         string
	Pt           types.PatchType
	Data         []byte
	Subresources []string
}

PatchCalls gets all the calls that were made to Patch. Check the length with:

len(mockedGitWatcherClient.PatchCalls())

func (*GitWatcherClientMock) Update

func (mock *GitWatcherClientMock) Update(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

Update calls UpdateFunc.

func (*GitWatcherClientMock) UpdateCalls

func (mock *GitWatcherClientMock) UpdateCalls() []struct {
	In1 *v1a.GitWatcher
}

UpdateCalls gets all the calls that were made to Update. Check the length with:

len(mockedGitWatcherClient.UpdateCalls())

func (*GitWatcherClientMock) UpdateStatus

func (mock *GitWatcherClientMock) UpdateStatus(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

UpdateStatus calls UpdateStatusFunc.

func (*GitWatcherClientMock) UpdateStatusCalls

func (mock *GitWatcherClientMock) UpdateStatusCalls() []struct {
	In1 *v1a.GitWatcher
}

UpdateStatusCalls gets all the calls that were made to UpdateStatus. Check the length with:

len(mockedGitWatcherClient.UpdateStatusCalls())

func (*GitWatcherClientMock) Watch

func (mock *GitWatcherClientMock) Watch(namespace string, opts v1b.ListOptions) (watch.Interface, error)

Watch calls WatchFunc.

func (*GitWatcherClientMock) WatchCalls

func (mock *GitWatcherClientMock) WatchCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

WatchCalls gets all the calls that were made to Watch. Check the length with:

len(mockedGitWatcherClient.WatchCalls())

type GitWatcherControllerMock

type GitWatcherControllerMock struct {
	// AddGenericHandlerFunc mocks the AddGenericHandler method.
	AddGenericHandlerFunc func(ctx context.Context, name string, handler generic.Handler)

	// AddGenericRemoveHandlerFunc mocks the AddGenericRemoveHandler method.
	AddGenericRemoveHandlerFunc func(ctx context.Context, name string, handler generic.Handler)

	// CacheFunc mocks the Cache method.
	CacheFunc func() v1.GitWatcherCache

	// CreateFunc mocks the Create method.
	CreateFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// DeleteFunc mocks the Delete method.
	DeleteFunc func(namespace string, name string, options *v1b.DeleteOptions) error

	// EnqueueFunc mocks the Enqueue method.
	EnqueueFunc func(namespace string, name string)

	// GetFunc mocks the Get method.
	GetFunc func(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error)

	// GroupVersionKindFunc mocks the GroupVersionKind method.
	GroupVersionKindFunc func() schema.GroupVersionKind

	// InformerFunc mocks the Informer method.
	InformerFunc func() cache.SharedIndexInformer

	// ListFunc mocks the List method.
	ListFunc func(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error)

	// OnChangeFunc mocks the OnChange method.
	OnChangeFunc func(ctx context.Context, name string, sync v1.GitWatcherHandler)

	// OnRemoveFunc mocks the OnRemove method.
	OnRemoveFunc func(ctx context.Context, name string, sync v1.GitWatcherHandler)

	// PatchFunc mocks the Patch method.
	PatchFunc func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error)

	// UpdateFunc mocks the Update method.
	UpdateFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// UpdateStatusFunc mocks the UpdateStatus method.
	UpdateStatusFunc func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

	// UpdaterFunc mocks the Updater method.
	UpdaterFunc func() generic.Updater

	// WatchFunc mocks the Watch method.
	WatchFunc func(namespace string, opts v1b.ListOptions) (watch.Interface, error)
	// contains filtered or unexported fields
}

GitWatcherControllerMock is a mock implementation of GitWatcherController.

    func TestSomethingThatUsesGitWatcherController(t *testing.T) {

        // make and configure a mocked GitWatcherController
        mockedGitWatcherController := &GitWatcherControllerMock{
            AddGenericHandlerFunc: func(ctx context.Context, name string, handler generic.Handler)  {
	               panic("mock out the AddGenericHandler method")
            },
            AddGenericRemoveHandlerFunc: func(ctx context.Context, name string, handler generic.Handler)  {
	               panic("mock out the AddGenericRemoveHandler method")
            },
            CacheFunc: func() v1.GitWatcherCache {
	               panic("mock out the Cache method")
            },
            CreateFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the Create method")
            },
            DeleteFunc: func(namespace string, name string, options *v1b.DeleteOptions) error {
	               panic("mock out the Delete method")
            },
            EnqueueFunc: func(namespace string, name string)  {
	               panic("mock out the Enqueue method")
            },
            GetFunc: func(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error) {
	               panic("mock out the Get method")
            },
            GroupVersionKindFunc: func() schema.GroupVersionKind {
	               panic("mock out the GroupVersionKind method")
            },
            InformerFunc: func() cache.SharedIndexInformer {
	               panic("mock out the Informer method")
            },
            ListFunc: func(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error) {
	               panic("mock out the List method")
            },
            OnChangeFunc: func(ctx context.Context, name string, sync v1.GitWatcherHandler)  {
	               panic("mock out the OnChange method")
            },
            OnRemoveFunc: func(ctx context.Context, name string, sync v1.GitWatcherHandler)  {
	               panic("mock out the OnRemove method")
            },
            PatchFunc: func(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error) {
	               panic("mock out the Patch method")
            },
            UpdateFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the Update method")
            },
            UpdateStatusFunc: func(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error) {
	               panic("mock out the UpdateStatus method")
            },
            UpdaterFunc: func() generic.Updater {
	               panic("mock out the Updater method")
            },
            WatchFunc: func(namespace string, opts v1b.ListOptions) (watch.Interface, error) {
	               panic("mock out the Watch method")
            },
        }

        // use mockedGitWatcherController in code that requires GitWatcherController
        // and then make assertions.

    }

func (*GitWatcherControllerMock) AddGenericHandler

func (mock *GitWatcherControllerMock) AddGenericHandler(ctx context.Context, name string, handler generic.Handler)

AddGenericHandler calls AddGenericHandlerFunc.

func (*GitWatcherControllerMock) AddGenericHandlerCalls

func (mock *GitWatcherControllerMock) AddGenericHandlerCalls() []struct {
	Ctx     context.Context
	Name    string
	Handler generic.Handler
}

AddGenericHandlerCalls gets all the calls that were made to AddGenericHandler. Check the length with:

len(mockedGitWatcherController.AddGenericHandlerCalls())

func (*GitWatcherControllerMock) AddGenericRemoveHandler

func (mock *GitWatcherControllerMock) AddGenericRemoveHandler(ctx context.Context, name string, handler generic.Handler)

AddGenericRemoveHandler calls AddGenericRemoveHandlerFunc.

func (*GitWatcherControllerMock) AddGenericRemoveHandlerCalls

func (mock *GitWatcherControllerMock) AddGenericRemoveHandlerCalls() []struct {
	Ctx     context.Context
	Name    string
	Handler generic.Handler
}

AddGenericRemoveHandlerCalls gets all the calls that were made to AddGenericRemoveHandler. Check the length with:

len(mockedGitWatcherController.AddGenericRemoveHandlerCalls())

func (*GitWatcherControllerMock) Cache

Cache calls CacheFunc.

func (*GitWatcherControllerMock) CacheCalls

func (mock *GitWatcherControllerMock) CacheCalls() []struct {
}

CacheCalls gets all the calls that were made to Cache. Check the length with:

len(mockedGitWatcherController.CacheCalls())

func (*GitWatcherControllerMock) Create

func (mock *GitWatcherControllerMock) Create(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

Create calls CreateFunc.

func (*GitWatcherControllerMock) CreateCalls

func (mock *GitWatcherControllerMock) CreateCalls() []struct {
	In1 *v1a.GitWatcher
}

CreateCalls gets all the calls that were made to Create. Check the length with:

len(mockedGitWatcherController.CreateCalls())

func (*GitWatcherControllerMock) Delete

func (mock *GitWatcherControllerMock) Delete(namespace string, name string, options *v1b.DeleteOptions) error

Delete calls DeleteFunc.

func (*GitWatcherControllerMock) DeleteCalls

func (mock *GitWatcherControllerMock) DeleteCalls() []struct {
	Namespace string
	Name      string
	Options   *v1b.DeleteOptions
}

DeleteCalls gets all the calls that were made to Delete. Check the length with:

len(mockedGitWatcherController.DeleteCalls())

func (*GitWatcherControllerMock) Enqueue

func (mock *GitWatcherControllerMock) Enqueue(namespace string, name string)

Enqueue calls EnqueueFunc.

func (*GitWatcherControllerMock) EnqueueCalls

func (mock *GitWatcherControllerMock) EnqueueCalls() []struct {
	Namespace string
	Name      string
}

EnqueueCalls gets all the calls that were made to Enqueue. Check the length with:

len(mockedGitWatcherController.EnqueueCalls())

func (*GitWatcherControllerMock) Get

func (mock *GitWatcherControllerMock) Get(namespace string, name string, options v1b.GetOptions) (*v1a.GitWatcher, error)

Get calls GetFunc.

func (*GitWatcherControllerMock) GetCalls

func (mock *GitWatcherControllerMock) GetCalls() []struct {
	Namespace string
	Name      string
	Options   v1b.GetOptions
}

GetCalls gets all the calls that were made to Get. Check the length with:

len(mockedGitWatcherController.GetCalls())

func (*GitWatcherControllerMock) GroupVersionKind

func (mock *GitWatcherControllerMock) GroupVersionKind() schema.GroupVersionKind

GroupVersionKind calls GroupVersionKindFunc.

func (*GitWatcherControllerMock) GroupVersionKindCalls

func (mock *GitWatcherControllerMock) GroupVersionKindCalls() []struct {
}

GroupVersionKindCalls gets all the calls that were made to GroupVersionKind. Check the length with:

len(mockedGitWatcherController.GroupVersionKindCalls())

func (*GitWatcherControllerMock) Informer

Informer calls InformerFunc.

func (*GitWatcherControllerMock) InformerCalls

func (mock *GitWatcherControllerMock) InformerCalls() []struct {
}

InformerCalls gets all the calls that were made to Informer. Check the length with:

len(mockedGitWatcherController.InformerCalls())

func (*GitWatcherControllerMock) List

func (mock *GitWatcherControllerMock) List(namespace string, opts v1b.ListOptions) (*v1a.GitWatcherList, error)

List calls ListFunc.

func (*GitWatcherControllerMock) ListCalls

func (mock *GitWatcherControllerMock) ListCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

ListCalls gets all the calls that were made to List. Check the length with:

len(mockedGitWatcherController.ListCalls())

func (*GitWatcherControllerMock) OnChange

func (mock *GitWatcherControllerMock) OnChange(ctx context.Context, name string, sync v1.GitWatcherHandler)

OnChange calls OnChangeFunc.

func (*GitWatcherControllerMock) OnChangeCalls

func (mock *GitWatcherControllerMock) OnChangeCalls() []struct {
	Ctx  context.Context
	Name string
	Sync v1.GitWatcherHandler
}

OnChangeCalls gets all the calls that were made to OnChange. Check the length with:

len(mockedGitWatcherController.OnChangeCalls())

func (*GitWatcherControllerMock) OnRemove

func (mock *GitWatcherControllerMock) OnRemove(ctx context.Context, name string, sync v1.GitWatcherHandler)

OnRemove calls OnRemoveFunc.

func (*GitWatcherControllerMock) OnRemoveCalls

func (mock *GitWatcherControllerMock) OnRemoveCalls() []struct {
	Ctx  context.Context
	Name string
	Sync v1.GitWatcherHandler
}

OnRemoveCalls gets all the calls that were made to OnRemove. Check the length with:

len(mockedGitWatcherController.OnRemoveCalls())

func (*GitWatcherControllerMock) Patch

func (mock *GitWatcherControllerMock) Patch(namespace string, name string, pt types.PatchType, data []byte, subresources ...string) (*v1a.GitWatcher, error)

Patch calls PatchFunc.

func (*GitWatcherControllerMock) PatchCalls

func (mock *GitWatcherControllerMock) PatchCalls() []struct {
	Namespace    string
	Name         string
	Pt           types.PatchType
	Data         []byte
	Subresources []string
}

PatchCalls gets all the calls that were made to Patch. Check the length with:

len(mockedGitWatcherController.PatchCalls())

func (*GitWatcherControllerMock) Update

func (mock *GitWatcherControllerMock) Update(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

Update calls UpdateFunc.

func (*GitWatcherControllerMock) UpdateCalls

func (mock *GitWatcherControllerMock) UpdateCalls() []struct {
	In1 *v1a.GitWatcher
}

UpdateCalls gets all the calls that were made to Update. Check the length with:

len(mockedGitWatcherController.UpdateCalls())

func (*GitWatcherControllerMock) UpdateStatus

func (mock *GitWatcherControllerMock) UpdateStatus(in1 *v1a.GitWatcher) (*v1a.GitWatcher, error)

UpdateStatus calls UpdateStatusFunc.

func (*GitWatcherControllerMock) UpdateStatusCalls

func (mock *GitWatcherControllerMock) UpdateStatusCalls() []struct {
	In1 *v1a.GitWatcher
}

UpdateStatusCalls gets all the calls that were made to UpdateStatus. Check the length with:

len(mockedGitWatcherController.UpdateStatusCalls())

func (*GitWatcherControllerMock) Updater

func (mock *GitWatcherControllerMock) Updater() generic.Updater

Updater calls UpdaterFunc.

func (*GitWatcherControllerMock) UpdaterCalls

func (mock *GitWatcherControllerMock) UpdaterCalls() []struct {
}

UpdaterCalls gets all the calls that were made to Updater. Check the length with:

len(mockedGitWatcherController.UpdaterCalls())

func (*GitWatcherControllerMock) Watch

func (mock *GitWatcherControllerMock) Watch(namespace string, opts v1b.ListOptions) (watch.Interface, error)

Watch calls WatchFunc.

func (*GitWatcherControllerMock) WatchCalls

func (mock *GitWatcherControllerMock) WatchCalls() []struct {
	Namespace string
	Opts      v1b.ListOptions
}

WatchCalls gets all the calls that were made to Watch. Check the length with:

len(mockedGitWatcherController.WatchCalls())

Jump to

Keyboard shortcuts

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