mocks

package
v0.0.0-...-e3cadf0 Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: GPL-3.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 Storage

type Storage struct {
	mock.Mock
}

Storage is an autogenerated mock type for the Storage type

func NewStorage

func NewStorage(t interface {
	mock.TestingT
	Cleanup(func())
}) *Storage

NewStorage creates a new instance of Storage. 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 (*Storage) AppendBacksides

func (_m *Storage) AppendBacksides(ctx context.Context, userId int, cardId int, backsides []models.Backside) error

AppendBacksides provides a mock function with given fields: ctx, userId, cardId, backsides

func (*Storage) DeleteFlashcardFromDeck

func (_m *Storage) DeleteFlashcardFromDeck(ctx context.Context, cardId int) error

DeleteFlashcardFromDeck provides a mock function with given fields: ctx, cardId

func (*Storage) DeleteLeitner

func (_m *Storage) DeleteLeitner(ctx context.Context, id int) error

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

func (*Storage) DeleteUserDeck

func (_m *Storage) DeleteUserDeck(ctx context.Context, userId int, id int) error

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

func (*Storage) GetDecksByUserId

func (_m *Storage) GetDecksByUserId(ctx context.Context, id int) (models.Decks, error)

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

func (*Storage) GetFlashcardById

func (_m *Storage) GetFlashcardById(ctx context.Context, id int) (models.Flashcard, error)

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

func (*Storage) GetFlashcardsIdByDeckId

func (_m *Storage) GetFlashcardsIdByDeckId(ctx context.Context, id int) ([]int, error)

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

func (*Storage) GetLeitnerByUserIdCardId

func (_m *Storage) GetLeitnerByUserIdCardId(ctx context.Context, id int, flashcardId int) (models.UserLeitner, error)

GetLeitnerByUserIdCardId provides a mock function with given fields: ctx, id, flashcardId

func (*Storage) GetRandomCardDeckN

func (_m *Storage) GetRandomCardDeckN(ctx context.Context, userId int, deckId int, down models.CoolDown, n int) ([]int, error)

GetRandomCardDeckN provides a mock function with given fields: ctx, userId, deckId, down, n

func (*Storage) GetUserInfo

func (_m *Storage) GetUserInfo(ctx context.Context, uid int) (models.UserInfo, error)

GetUserInfo provides a mock function with given fields: ctx, uid

func (*Storage) PutAllFlashcards

func (_m *Storage) PutAllFlashcards(ctx context.Context, id int, cards []models.Flashcard) ([]int, error)

PutAllFlashcards provides a mock function with given fields: ctx, id, cards

func (*Storage) PutAllUserLeitner

func (_m *Storage) PutAllUserLeitner(ctx context.Context, uls []models.UserLeitner) ([]int, error)

PutAllUserLeitner provides a mock function with given fields: ctx, uls

func (*Storage) PutNewDeck

func (_m *Storage) PutNewDeck(ctx context.Context, config models.DeckConfig) (int, error)

PutNewDeck provides a mock function with given fields: ctx, config

func (*Storage) UpdateDeck

func (_m *Storage) UpdateDeck(ctx context.Context, deck models.DeckConfig) error

UpdateDeck provides a mock function with given fields: ctx, deck

func (*Storage) UpdateFlashcard

func (_m *Storage) UpdateFlashcard(ctx context.Context, id int, w string, b models.Backside, a string) error

UpdateFlashcard provides a mock function with given fields: ctx, id, w, b, a

func (*Storage) UpdateLeitner

func (_m *Storage) UpdateLeitner(ctx context.Context, ul models.UserLeitner) error

UpdateLeitner provides a mock function with given fields: ctx, ul

Jump to

Keyboard shortcuts

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