mocks

package
v0.0.0-...-bf79d3d Latest Latest
Warning

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

Go to latest
Published: Dec 27, 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 BooksRepository

type BooksRepository struct {
	mock.Mock
}

BooksRepository is an autogenerated mock type for the BooksRepository type

func NewBooksRepository

func NewBooksRepository(t interface {
	mock.TestingT
	Cleanup(func())
}) *BooksRepository

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

func (_m *BooksRepository) Create(ctx context.Context, title string, author string) (*models.Book, error)

Create provides a mock function with given fields: ctx, title, author

func (*BooksRepository) DeleteById

func (_m *BooksRepository) DeleteById(ctx context.Context, id string) error

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

func (*BooksRepository) GetById

func (_m *BooksRepository) GetById(ctx context.Context, id string) (*models.Book, error)

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

func (*BooksRepository) GetByTitle

func (_m *BooksRepository) GetByTitle(ctx context.Context, title string) (*models.Book, error)

GetByTitle provides a mock function with given fields: ctx, title

type RefreshTokensRepository

type RefreshTokensRepository struct {
	mock.Mock
}

RefreshTokensRepository is an autogenerated mock type for the RefreshTokensRepository type

func NewRefreshTokensRepository

func NewRefreshTokensRepository(t interface {
	mock.TestingT
	Cleanup(func())
}) *RefreshTokensRepository

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

func (_m *RefreshTokensRepository) Create(ctx context.Context, id string, refreshToken string, userId uuid.UUID) error

Create provides a mock function with given fields: ctx, id, refreshToken, userId

func (*RefreshTokensRepository) Delete

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

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

func (*RefreshTokensRepository) DeleteByUserID

func (_m *RefreshTokensRepository) DeleteByUserID(ctx context.Context, userID uuid.UUID) error

DeleteByUserID provides a mock function with given fields: ctx, userID

func (*RefreshTokensRepository) Get

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

type UsersRepository

type UsersRepository struct {
	mock.Mock
}

UsersRepository is an autogenerated mock type for the UsersRepository type

func NewUsersRepository

func NewUsersRepository(t interface {
	mock.TestingT
	Cleanup(func())
}) *UsersRepository

NewUsersRepository creates a new instance of UsersRepository. 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 (*UsersRepository) ExistsById

func (_m *UsersRepository) ExistsById(ctx context.Context, userId uuid.UUID) (bool, error)

ExistsById provides a mock function with given fields: ctx, userId

func (*UsersRepository) Get

func (_m *UsersRepository) Get(ctx context.Context, id uuid.UUID) (*models.User, error)

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

func (*UsersRepository) GetByUsername

func (_m *UsersRepository) GetByUsername(ctx context.Context, username string) (*models.User, error)

GetByUsername provides a mock function with given fields: ctx, username

Jump to

Keyboard shortcuts

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