mocks

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockAPIClient

type MockAPIClient struct {
	mock.Mock
}

MockAPIClient is an autogenerated mock type for the APIClient type

func NewMockAPIClient

func NewMockAPIClient(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockAPIClient

NewMockAPIClient creates a new instance of MockAPIClient. 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 (*MockAPIClient) CreateRelease

func (_m *MockAPIClient) CreateRelease(owner string, repo string, opt gitea.CreateReleaseOption) (*gitea.Release, *gitea.Response, error)

CreateRelease provides a mock function with given fields: owner, repo, opt

func (*MockAPIClient) CreateReleaseAttachment

func (_m *MockAPIClient) CreateReleaseAttachment(user string, repo string, release int64, file io.Reader, filename string) (*gitea.Attachment, *gitea.Response, error)

CreateReleaseAttachment provides a mock function with given fields: user, repo, release, file, filename

func (*MockAPIClient) DeleteReleaseAttachment

func (_m *MockAPIClient) DeleteReleaseAttachment(user string, repo string, release int64, id int64) (*gitea.Response, error)

DeleteReleaseAttachment provides a mock function with given fields: user, repo, release, id

func (*MockAPIClient) EXPECT

func (_m *MockAPIClient) EXPECT() *MockAPIClient_Expecter

func (*MockAPIClient) ListReleaseAttachments

func (_m *MockAPIClient) ListReleaseAttachments(user string, repo string, release int64, opt gitea.ListReleaseAttachmentsOptions) ([]*gitea.Attachment, *gitea.Response, error)

ListReleaseAttachments provides a mock function with given fields: user, repo, release, opt

func (*MockAPIClient) ListReleases

func (_m *MockAPIClient) ListReleases(owner string, repo string, opt gitea.ListReleasesOptions) ([]*gitea.Release, *gitea.Response, error)

ListReleases provides a mock function with given fields: owner, repo, opt

type MockAPIClient_CreateReleaseAttachment_Call

type MockAPIClient_CreateReleaseAttachment_Call struct {
	*mock.Call
}

MockAPIClient_CreateReleaseAttachment_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateReleaseAttachment'

func (*MockAPIClient_CreateReleaseAttachment_Call) Return

func (*MockAPIClient_CreateReleaseAttachment_Call) Run

func (*MockAPIClient_CreateReleaseAttachment_Call) RunAndReturn

type MockAPIClient_CreateRelease_Call

type MockAPIClient_CreateRelease_Call struct {
	*mock.Call
}

MockAPIClient_CreateRelease_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateRelease'

func (*MockAPIClient_CreateRelease_Call) Return

func (*MockAPIClient_CreateRelease_Call) Run

func (*MockAPIClient_CreateRelease_Call) RunAndReturn

type MockAPIClient_DeleteReleaseAttachment_Call

type MockAPIClient_DeleteReleaseAttachment_Call struct {
	*mock.Call
}

MockAPIClient_DeleteReleaseAttachment_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteReleaseAttachment'

func (*MockAPIClient_DeleteReleaseAttachment_Call) Return

func (*MockAPIClient_DeleteReleaseAttachment_Call) Run

func (*MockAPIClient_DeleteReleaseAttachment_Call) RunAndReturn

type MockAPIClient_Expecter

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

func (*MockAPIClient_Expecter) CreateRelease

func (_e *MockAPIClient_Expecter) CreateRelease(owner interface{}, repo interface{}, opt interface{}) *MockAPIClient_CreateRelease_Call

CreateRelease is a helper method to define mock.On call

  • owner string
  • repo string
  • opt gitea.CreateReleaseOption

func (*MockAPIClient_Expecter) CreateReleaseAttachment

func (_e *MockAPIClient_Expecter) CreateReleaseAttachment(user interface{}, repo interface{}, release interface{}, file interface{}, filename interface{}) *MockAPIClient_CreateReleaseAttachment_Call

CreateReleaseAttachment is a helper method to define mock.On call

  • user string
  • repo string
  • release int64
  • file io.Reader
  • filename string

func (*MockAPIClient_Expecter) DeleteReleaseAttachment

func (_e *MockAPIClient_Expecter) DeleteReleaseAttachment(user interface{}, repo interface{}, release interface{}, id interface{}) *MockAPIClient_DeleteReleaseAttachment_Call

DeleteReleaseAttachment is a helper method to define mock.On call

  • user string
  • repo string
  • release int64
  • id int64

func (*MockAPIClient_Expecter) ListReleaseAttachments

func (_e *MockAPIClient_Expecter) ListReleaseAttachments(user interface{}, repo interface{}, release interface{}, opt interface{}) *MockAPIClient_ListReleaseAttachments_Call

ListReleaseAttachments is a helper method to define mock.On call

  • user string
  • repo string
  • release int64
  • opt gitea.ListReleaseAttachmentsOptions

func (*MockAPIClient_Expecter) ListReleases

func (_e *MockAPIClient_Expecter) ListReleases(owner interface{}, repo interface{}, opt interface{}) *MockAPIClient_ListReleases_Call

ListReleases is a helper method to define mock.On call

  • owner string
  • repo string
  • opt gitea.ListReleasesOptions

type MockAPIClient_ListReleaseAttachments_Call

type MockAPIClient_ListReleaseAttachments_Call struct {
	*mock.Call
}

MockAPIClient_ListReleaseAttachments_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListReleaseAttachments'

func (*MockAPIClient_ListReleaseAttachments_Call) Return

func (*MockAPIClient_ListReleaseAttachments_Call) Run

type MockAPIClient_ListReleases_Call

type MockAPIClient_ListReleases_Call struct {
	*mock.Call
}

MockAPIClient_ListReleases_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListReleases'

func (*MockAPIClient_ListReleases_Call) Return

func (*MockAPIClient_ListReleases_Call) Run

func (*MockAPIClient_ListReleases_Call) RunAndReturn

Jump to

Keyboard shortcuts

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