mocks

package
v0.0.0-...-d903cca Latest Latest
Warning

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

Go to latest
Published: May 31, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LoginUsecase

type LoginUsecase struct {
	mock.Mock
}

LoginUsecase is an autogenerated mock type for the LoginUsecase type

func NewLoginUsecase

func NewLoginUsecase(t mockConstructorTestingTNewLoginUsecase) *LoginUsecase

NewLoginUsecase creates a new instance of LoginUsecase. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*LoginUsecase) CreateAccessToken

func (_m *LoginUsecase) CreateAccessToken(user *domain.User, secret string, expiry int) (string, error)

CreateAccessToken provides a mock function with given fields: user, secret, expiry

func (*LoginUsecase) CreateRefreshToken

func (_m *LoginUsecase) CreateRefreshToken(user *domain.User, secret string, expiry int) (string, error)

CreateRefreshToken provides a mock function with given fields: user, secret, expiry

func (*LoginUsecase) GetUserByEmail

func (_m *LoginUsecase) GetUserByEmail(c context.Context, email string) (domain.User, error)

GetUserByEmail provides a mock function with given fields: c, email

type ProfileUsecase

type ProfileUsecase struct {
	mock.Mock
}

ProfileUsecase is an autogenerated mock type for the ProfileUsecase type

func NewProfileUsecase

func NewProfileUsecase(t mockConstructorTestingTNewProfileUsecase) *ProfileUsecase

NewProfileUsecase creates a new instance of ProfileUsecase. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*ProfileUsecase) GetProfileByID

func (_m *ProfileUsecase) GetProfileByID(c context.Context, userID string) (*domain.Profile, error)

GetProfileByID provides a mock function with given fields: c, userID

type RefreshTokenUsecase

type RefreshTokenUsecase struct {
	mock.Mock
}

RefreshTokenUsecase is an autogenerated mock type for the RefreshTokenUsecase type

func NewRefreshTokenUsecase

func NewRefreshTokenUsecase(t mockConstructorTestingTNewRefreshTokenUsecase) *RefreshTokenUsecase

NewRefreshTokenUsecase creates a new instance of RefreshTokenUsecase. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*RefreshTokenUsecase) CreateAccessToken

func (_m *RefreshTokenUsecase) CreateAccessToken(user *domain.User, secret string, expiry int) (string, error)

CreateAccessToken provides a mock function with given fields: user, secret, expiry

func (*RefreshTokenUsecase) CreateRefreshToken

func (_m *RefreshTokenUsecase) CreateRefreshToken(user *domain.User, secret string, expiry int) (string, error)

CreateRefreshToken provides a mock function with given fields: user, secret, expiry

func (*RefreshTokenUsecase) ExtractIDFromToken

func (_m *RefreshTokenUsecase) ExtractIDFromToken(requestToken string, secret string) (string, error)

ExtractIDFromToken provides a mock function with given fields: requestToken, secret

func (*RefreshTokenUsecase) GetUserByID

func (_m *RefreshTokenUsecase) GetUserByID(c context.Context, id string) (domain.User, error)

GetUserByID provides a mock function with given fields: c, id

type SignupUsecase

type SignupUsecase struct {
	mock.Mock
}

SignupUsecase is an autogenerated mock type for the SignupUsecase type

func NewSignupUsecase

func NewSignupUsecase(t mockConstructorTestingTNewSignupUsecase) *SignupUsecase

NewSignupUsecase creates a new instance of SignupUsecase. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*SignupUsecase) Create

func (_m *SignupUsecase) Create(c context.Context, user *domain.User) error

Create provides a mock function with given fields: c, user

func (*SignupUsecase) CreateAccessToken

func (_m *SignupUsecase) CreateAccessToken(user *domain.User, secret string, expiry int) (string, error)

CreateAccessToken provides a mock function with given fields: user, secret, expiry

func (*SignupUsecase) CreateRefreshToken

func (_m *SignupUsecase) CreateRefreshToken(user *domain.User, secret string, expiry int) (string, error)

CreateRefreshToken provides a mock function with given fields: user, secret, expiry

func (*SignupUsecase) GetUserByEmail

func (_m *SignupUsecase) GetUserByEmail(c context.Context, email string) (domain.User, error)

GetUserByEmail provides a mock function with given fields: c, email

type UserRepository

type UserRepository struct {
	mock.Mock
}

UserRepository is an autogenerated mock type for the UserRepository type

func NewUserRepository

func NewUserRepository(t mockConstructorTestingTNewUserRepository) *UserRepository

NewUserRepository creates a new instance of UserRepository. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*UserRepository) Create

func (_m *UserRepository) Create(c context.Context, user *domain.User) error

Create provides a mock function with given fields: c, user

func (*UserRepository) Fetch

func (_m *UserRepository) Fetch(c context.Context) ([]domain.User, error)

Fetch provides a mock function with given fields: c

func (*UserRepository) GetUserByEmail

func (_m *UserRepository) GetUserByEmail(c context.Context, email string) (domain.User, error)

GetByEmail provides a mock function with given fields: c, email

func (*UserRepository) GetUserByID

func (_m *UserRepository) GetUserByID(c context.Context, id string) (domain.User, error)

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

func (*UserRepository) GetUserByUserName

func (_m *UserRepository) GetUserByUserName(c context.Context, username string) (domain.User, error)

Jump to

Keyboard shortcuts

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