mocks

package
v0.41.0 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 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 Repository

type Repository struct {
	mock.Mock
}

Repository is an autogenerated mock type for the Repository type

func NewRepository

func NewRepository(t interface {
	mock.TestingT
	Cleanup(func())
}) *Repository

NewRepository creates a new instance of Repository. 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 (*Repository) Delete

func (_m *Repository) Delete(ctx context.Context, id uuid.UUID) error

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

func (*Repository) DeleteExpiredSessions

func (_m *Repository) DeleteExpiredSessions(ctx context.Context) error

DeleteExpiredSessions provides a mock function with given fields: ctx

func (*Repository) EXPECT

func (_m *Repository) EXPECT() *Repository_Expecter

func (*Repository) Get

func (_m *Repository) Get(ctx context.Context, id uuid.UUID) (*session.Session, error)

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

func (*Repository) Set

func (_m *Repository) Set(ctx context.Context, _a1 *session.Session) error

Set provides a mock function with given fields: ctx, _a1

func (*Repository) UpdateValidity

func (_m *Repository) UpdateValidity(ctx context.Context, id uuid.UUID, validity time.Duration) error

UpdateValidity provides a mock function with given fields: ctx, id, validity

type Repository_DeleteExpiredSessions_Call

type Repository_DeleteExpiredSessions_Call struct {
	*mock.Call
}

Repository_DeleteExpiredSessions_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteExpiredSessions'

func (*Repository_DeleteExpiredSessions_Call) Return

func (*Repository_DeleteExpiredSessions_Call) Run

func (*Repository_DeleteExpiredSessions_Call) RunAndReturn

type Repository_Delete_Call

type Repository_Delete_Call struct {
	*mock.Call
}

Repository_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'

func (*Repository_Delete_Call) Return

func (*Repository_Delete_Call) Run

func (*Repository_Delete_Call) RunAndReturn

type Repository_Expecter

type Repository_Expecter struct {
	// contains filtered or unexported fields
}

func (*Repository_Expecter) Delete

func (_e *Repository_Expecter) Delete(ctx interface{}, id interface{}) *Repository_Delete_Call

Delete is a helper method to define mock.On call

  • ctx context.Context
  • id uuid.UUID

func (*Repository_Expecter) DeleteExpiredSessions

func (_e *Repository_Expecter) DeleteExpiredSessions(ctx interface{}) *Repository_DeleteExpiredSessions_Call

DeleteExpiredSessions is a helper method to define mock.On call

  • ctx context.Context

func (*Repository_Expecter) Get

func (_e *Repository_Expecter) Get(ctx interface{}, id interface{}) *Repository_Get_Call

Get is a helper method to define mock.On call

  • ctx context.Context
  • id uuid.UUID

func (*Repository_Expecter) Set

func (_e *Repository_Expecter) Set(ctx interface{}, _a1 interface{}) *Repository_Set_Call

Set is a helper method to define mock.On call

  • ctx context.Context
  • _a1 *session.Session

func (*Repository_Expecter) UpdateValidity

func (_e *Repository_Expecter) UpdateValidity(ctx interface{}, id interface{}, validity interface{}) *Repository_UpdateValidity_Call

UpdateValidity is a helper method to define mock.On call

  • ctx context.Context
  • id uuid.UUID
  • validity time.Duration

type Repository_Get_Call

type Repository_Get_Call struct {
	*mock.Call
}

Repository_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*Repository_Get_Call) Return

func (*Repository_Get_Call) Run

func (_c *Repository_Get_Call) Run(run func(ctx context.Context, id uuid.UUID)) *Repository_Get_Call

func (*Repository_Get_Call) RunAndReturn

type Repository_Set_Call

type Repository_Set_Call struct {
	*mock.Call
}

Repository_Set_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Set'

func (*Repository_Set_Call) Return

func (*Repository_Set_Call) Run

func (_c *Repository_Set_Call) Run(run func(ctx context.Context, _a1 *session.Session)) *Repository_Set_Call

func (*Repository_Set_Call) RunAndReturn

type Repository_UpdateValidity_Call

type Repository_UpdateValidity_Call struct {
	*mock.Call
}

Repository_UpdateValidity_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateValidity'

func (*Repository_UpdateValidity_Call) Return

func (*Repository_UpdateValidity_Call) Run

func (*Repository_UpdateValidity_Call) RunAndReturn

Jump to

Keyboard shortcuts

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