mocks

package
v0.0.0-...-273c5a8 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AzureTranslationClient

type AzureTranslationClient struct {
	mock.Mock
}

AzureTranslationClient is an autogenerated mock type for the AzureTranslationClient type

func NewAzureTranslationClient

func NewAzureTranslationClient(t testing.TB) *AzureTranslationClient

NewAzureTranslationClient creates a new instance of AzureTranslationClient. It also registers a cleanup function to assert the mocks expectations.

func (*AzureTranslationClient) DictionaryLookup

func (_m *AzureTranslationClient) DictionaryLookup(ctx context.Context, text string, fromLang domain.Lang2, toLang domain.Lang2) ([]service.AzureTranslation, error)

DictionaryLookup provides a mock function with given fields: ctx, text, fromLang, toLang

type AzureTranslationRepository

type AzureTranslationRepository struct {
	mock.Mock
}

AzureTranslationRepository is an autogenerated mock type for the AzureTranslationRepository type

func NewAzureTranslationRepository

func NewAzureTranslationRepository(t testing.TB) *AzureTranslationRepository

NewAzureTranslationRepository creates a new instance of AzureTranslationRepository. It also registers a cleanup function to assert the mocks expectations.

func (*AzureTranslationRepository) Add

Add provides a mock function with given fields: ctx, lang2, text, result

func (*AzureTranslationRepository) Contain

func (_m *AzureTranslationRepository) Contain(ctx context.Context, lang2 domain.Lang2, text string) (bool, error)

Contain provides a mock function with given fields: ctx, lang2, text

func (*AzureTranslationRepository) Find

Find provides a mock function with given fields: ctx, lang2, text

func (*AzureTranslationRepository) FindByFirstLetter

func (_m *AzureTranslationRepository) FindByFirstLetter(ctx context.Context, lang2 domain.Lang2, firstLetter string) ([]domain.Translation, error)

FindByFirstLetter provides a mock function with given fields: ctx, lang2, firstLetter

func (*AzureTranslationRepository) FindByText

func (_m *AzureTranslationRepository) FindByText(ctx context.Context, lang2 domain.Lang2, text string) ([]domain.Translation, error)

FindByText provides a mock function with given fields: ctx, lang2, text

func (*AzureTranslationRepository) FindByTextAndPos

func (_m *AzureTranslationRepository) FindByTextAndPos(ctx context.Context, lang2 domain.Lang2, text string, pos domain.WordPos) (domain.Translation, error)

FindByTextAndPos provides a mock function with given fields: ctx, lang2, text, pos

type CustomTranslationRepository

type CustomTranslationRepository struct {
	mock.Mock
}

CustomTranslationRepository is an autogenerated mock type for the CustomTranslationRepository type

func NewCustomTranslationRepository

func NewCustomTranslationRepository(t testing.TB) *CustomTranslationRepository

NewCustomTranslationRepository creates a new instance of CustomTranslationRepository. It also registers a cleanup function to assert the mocks expectations.

func (*CustomTranslationRepository) Add

Add provides a mock function with given fields: ctx, param

func (*CustomTranslationRepository) Contain

func (_m *CustomTranslationRepository) Contain(ctx context.Context, lang2 domain.Lang2, text string) (bool, error)

Contain provides a mock function with given fields: ctx, lang2, text

func (*CustomTranslationRepository) FindByFirstLetter

func (_m *CustomTranslationRepository) FindByFirstLetter(ctx context.Context, lang2 domain.Lang2, firstLetter string) ([]domain.Translation, error)

FindByFirstLetter provides a mock function with given fields: ctx, lang2, firstLetter

func (*CustomTranslationRepository) FindByText

func (_m *CustomTranslationRepository) FindByText(ctx context.Context, lang2 domain.Lang2, text string) ([]domain.Translation, error)

FindByText provides a mock function with given fields: ctx, lang2, text

func (*CustomTranslationRepository) FindByTextAndPos

func (_m *CustomTranslationRepository) FindByTextAndPos(ctx context.Context, lang2 domain.Lang2, text string, pos domain.WordPos) (domain.Translation, error)

FindByTextAndPos provides a mock function with given fields: ctx, lang2, text, pos

func (*CustomTranslationRepository) Remove

func (_m *CustomTranslationRepository) Remove(ctx context.Context, lang2 domain.Lang2, text string, pos domain.WordPos) error

Remove provides a mock function with given fields: ctx, lang2, text, pos

func (*CustomTranslationRepository) Update

Update provides a mock function with given fields: ctx, lang2, text, pos, param

type RepositoryFactory

type RepositoryFactory struct {
	mock.Mock
}

RepositoryFactory is an autogenerated mock type for the RepositoryFactory type

func NewRepositoryFactory

func NewRepositoryFactory(t testing.TB) *RepositoryFactory

NewRepositoryFactory creates a new instance of RepositoryFactory. It also registers a cleanup function to assert the mocks expectations.

func (*RepositoryFactory) NewAzureTranslationRepository

func (_m *RepositoryFactory) NewAzureTranslationRepository(ctx context.Context) service.AzureTranslationRepository

NewAzureTranslationRepository provides a mock function with given fields: ctx

func (*RepositoryFactory) NewCustomTranslationRepository

func (_m *RepositoryFactory) NewCustomTranslationRepository(ctx context.Context) service.CustomTranslationRepository

NewCustomTranslationRepository provides a mock function with given fields: ctx

type TranslationUpdateParameter

type TranslationUpdateParameter struct {
	mock.Mock
}

TranslationUpdateParameter is an autogenerated mock type for the TranslationUpdateParameter type

func NewTranslationUpdateParameter

func NewTranslationUpdateParameter(t testing.TB) *TranslationUpdateParameter

NewTranslationUpdateParameter creates a new instance of TranslationUpdateParameter. It also registers a cleanup function to assert the mocks expectations.

func (*TranslationUpdateParameter) GetTranslated

func (_m *TranslationUpdateParameter) GetTranslated() string

GetTranslated provides a mock function with given fields:

Jump to

Keyboard shortcuts

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