mocks

package
v0.0.0-...-db2bfc3 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2024 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 Auth

type Auth struct {
	mock.Mock
}

Auth is an autogenerated mock type for the auth type

func NewAuth

func NewAuth(t interface {
	mock.TestingT
	Cleanup(func())
}) *Auth

NewAuth creates a new instance of Auth. 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 (*Auth) GenerateToken

func (_m *Auth) GenerateToken(user entity.User) (string, error)

GenerateToken provides a mock function with given fields: user

type Config

type Config struct {
	mock.Mock
}

Config is an autogenerated mock type for the config type

func NewConfig

func NewConfig(t interface {
	mock.TestingT
	Cleanup(func())
}) *Config

NewConfig creates a new instance of Config. 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 (*Config) GetTokenLifeTime

func (_m *Config) GetTokenLifeTime() time.Duration

GetTokenLifeTime provides a mock function with given fields:

func (*Config) GetTokenName

func (_m *Config) GetTokenName() string

GetTokenName provides a mock function with given fields:

type Ctxinfo

type Ctxinfo struct {
	mock.Mock
}

Ctxinfo is an autogenerated mock type for the ctxinfo type

func NewCtxinfo

func NewCtxinfo(t interface {
	mock.TestingT
	Cleanup(func())
}) *Ctxinfo

NewCtxinfo creates a new instance of Ctxinfo. 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 (*Ctxinfo) GetUserIDFromCtx

func (_m *Ctxinfo) GetUserIDFromCtx(c *gin.Context) (int64, error)

GetUserIDFromCtx provides a mock function with given fields: c

type Usecase

type Usecase struct {
	mock.Mock
}

Usecase is an autogenerated mock type for the usecase type

func NewUsecase

func NewUsecase(t interface {
	mock.TestingT
	Cleanup(func())
}) *Usecase

NewUsecase creates a new instance of Usecase. 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 (*Usecase) AddOrder

func (_m *Usecase) AddOrder(ctx context.Context, order entity.Order, user entity.User) error

AddOrder provides a mock function with given fields: ctx, order, user

func (*Usecase) GetAllOrders

func (_m *Usecase) GetAllOrders(ctx context.Context, user entity.User) ([]entity.Order, error)

GetAllOrders provides a mock function with given fields: ctx, user

func (*Usecase) GetBalance

func (_m *Usecase) GetBalance(ctx context.Context, user entity.User) (entity.Balance, error)

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

func (*Usecase) GetUser

func (_m *Usecase) GetUser(ctx context.Context, userFromReq entity.User) (entity.User, error)

GetUser provides a mock function with given fields: ctx, userFromReq

func (*Usecase) UserLogin

func (_m *Usecase) UserLogin(ctx context.Context, user entity.User) error

UserLogin provides a mock function with given fields: ctx, user

func (*Usecase) UserRegister

func (_m *Usecase) UserRegister(ctx context.Context, user entity.User) (int64, error)

UserRegister provides a mock function with given fields: ctx, user

func (*Usecase) WithdrawBalance

func (_m *Usecase) WithdrawBalance(ctx context.Context, balance entity.BalanceUpdate, user entity.User) error

WithdrawBalance provides a mock function with given fields: ctx, balance, user

func (*Usecase) Withdrawals

func (_m *Usecase) Withdrawals(ctx context.Context, user entity.User) ([]entity.BalanceUpdate, error)

Withdrawals provides a mock function with given fields: ctx, user

Jump to

Keyboard shortcuts

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