mocks

package
v0.42.0 Latest Latest
Warning

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

Go to latest
Published: Dec 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 CreditService added in v0.34.0

type CreditService struct {
	mock.Mock
}

CreditService is an autogenerated mock type for the CreditService type

func NewCreditService added in v0.34.0

func NewCreditService(t interface {
	mock.TestingT
	Cleanup(func())
}) *CreditService

NewCreditService creates a new instance of CreditService. 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 (*CreditService) EXPECT added in v0.34.0

func (_m *CreditService) EXPECT() *CreditService_Expecter

func (*CreditService) GetBalance added in v0.34.0

func (_m *CreditService) GetBalance(ctx context.Context, id string) (int64, error)

GetBalance provides a mock function with given fields: ctx, id

type CreditService_Expecter added in v0.34.0

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

func (*CreditService_Expecter) GetBalance added in v0.34.0

func (_e *CreditService_Expecter) GetBalance(ctx interface{}, id interface{}) *CreditService_GetBalance_Call

GetBalance is a helper method to define mock.On call

  • ctx context.Context
  • id string

type CreditService_GetBalance_Call added in v0.34.0

type CreditService_GetBalance_Call struct {
	*mock.Call
}

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

func (*CreditService_GetBalance_Call) Return added in v0.34.0

func (*CreditService_GetBalance_Call) Run added in v0.34.0

func (*CreditService_GetBalance_Call) RunAndReturn added in v0.34.0

type Repository

type Repository struct {
	mock.Mock
}

Repository is an autogenerated mock type for the Repository type

func NewRepository

func NewRepository(t interface {
	mock.TestingT
	Cleanup(func())
}) *Repository

NewRepository creates a new instance of Repository. 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 (*Repository) Create

Create provides a mock function with given fields: ctx, _a1

func (*Repository) Delete

func (_m *Repository) Delete(ctx context.Context, id string) error

Delete provides a mock function with given fields: ctx, id

func (*Repository) EXPECT

func (_m *Repository) EXPECT() *Repository_Expecter

func (*Repository) GetByID

func (_m *Repository) GetByID(ctx context.Context, id string) (customer.Customer, error)

GetByID provides a mock function with given fields: ctx, id

func (*Repository) List

func (_m *Repository) List(ctx context.Context, filter customer.Filter) ([]customer.Customer, error)

List provides a mock function with given fields: ctx, filter

func (*Repository) UpdateByID

func (_m *Repository) UpdateByID(ctx context.Context, _a1 customer.Customer) (customer.Customer, error)

UpdateByID provides a mock function with given fields: ctx, _a1

func (*Repository) UpdateCreditMinByID added in v0.34.0

func (_m *Repository) UpdateCreditMinByID(ctx context.Context, customerID string, limit int64) (customer.Customer, error)

UpdateCreditMinByID provides a mock function with given fields: ctx, customerID, limit

type Repository_Create_Call

type Repository_Create_Call struct {
	*mock.Call
}

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

func (*Repository_Create_Call) Return

func (*Repository_Create_Call) Run

func (*Repository_Create_Call) RunAndReturn

type Repository_Delete_Call

type Repository_Delete_Call struct {
	*mock.Call
}

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

func (*Repository_Delete_Call) Return

func (*Repository_Delete_Call) Run

func (*Repository_Delete_Call) RunAndReturn

type Repository_Expecter

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

func (*Repository_Expecter) Create

func (_e *Repository_Expecter) Create(ctx interface{}, _a1 interface{}) *Repository_Create_Call

Create is a helper method to define mock.On call

  • ctx context.Context
  • _a1 customer.Customer

func (*Repository_Expecter) Delete

func (_e *Repository_Expecter) Delete(ctx interface{}, id interface{}) *Repository_Delete_Call

Delete is a helper method to define mock.On call

  • ctx context.Context
  • id string

func (*Repository_Expecter) GetByID

func (_e *Repository_Expecter) GetByID(ctx interface{}, id interface{}) *Repository_GetByID_Call

GetByID is a helper method to define mock.On call

  • ctx context.Context
  • id string

func (*Repository_Expecter) List

func (_e *Repository_Expecter) List(ctx interface{}, filter interface{}) *Repository_List_Call

List is a helper method to define mock.On call

  • ctx context.Context
  • filter customer.Filter

func (*Repository_Expecter) UpdateByID

func (_e *Repository_Expecter) UpdateByID(ctx interface{}, _a1 interface{}) *Repository_UpdateByID_Call

UpdateByID is a helper method to define mock.On call

  • ctx context.Context
  • _a1 customer.Customer

func (*Repository_Expecter) UpdateCreditMinByID added in v0.34.0

func (_e *Repository_Expecter) UpdateCreditMinByID(ctx interface{}, customerID interface{}, limit interface{}) *Repository_UpdateCreditMinByID_Call

UpdateCreditMinByID is a helper method to define mock.On call

  • ctx context.Context
  • customerID string
  • limit int64

type Repository_GetByID_Call

type Repository_GetByID_Call struct {
	*mock.Call
}

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

func (*Repository_GetByID_Call) Return

func (*Repository_GetByID_Call) Run

func (*Repository_GetByID_Call) RunAndReturn

type Repository_List_Call

type Repository_List_Call struct {
	*mock.Call
}

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

func (*Repository_List_Call) Return

func (*Repository_List_Call) Run

func (_c *Repository_List_Call) Run(run func(ctx context.Context, filter customer.Filter)) *Repository_List_Call

func (*Repository_List_Call) RunAndReturn

type Repository_UpdateByID_Call

type Repository_UpdateByID_Call struct {
	*mock.Call
}

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

func (*Repository_UpdateByID_Call) Return

func (*Repository_UpdateByID_Call) Run

func (*Repository_UpdateByID_Call) RunAndReturn

type Repository_UpdateCreditMinByID_Call added in v0.34.0

type Repository_UpdateCreditMinByID_Call struct {
	*mock.Call
}

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

func (*Repository_UpdateCreditMinByID_Call) Return added in v0.34.0

func (*Repository_UpdateCreditMinByID_Call) Run added in v0.34.0

func (*Repository_UpdateCreditMinByID_Call) RunAndReturn added in v0.34.0

Jump to

Keyboard shortcuts

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