mocks

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2025 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 AuthManager

type AuthManager struct {
	mock.Mock
}

AuthManager is an autogenerated mock type for the AuthManager type

func NewAuthManager

func NewAuthManager(t interface {
	mock.TestingT
	Cleanup(func())
}) *AuthManager

NewAuthManager creates a new instance of AuthManager. 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 (*AuthManager) CreateNewPair

func (_mock *AuthManager) CreateNewPair(ctx context.Context, user models.User) (*auth.TokenPair, error)

CreateNewPair provides a mock function for the type AuthManager

func (*AuthManager) EXPECT

func (_m *AuthManager) EXPECT() *AuthManager_Expecter

func (*AuthManager) Parse

func (_mock *AuthManager) Parse(tokenStr string) (*auth.Claims, error)

Parse provides a mock function for the type AuthManager

func (*AuthManager) Refresh

func (_mock *AuthManager) Refresh(ctx context.Context, refreshToken string) (*auth.TokenPair, error)

Refresh provides a mock function for the type AuthManager

func (*AuthManager) RevokeAllUserTokens

func (_mock *AuthManager) RevokeAllUserTokens(ctx context.Context, userID uuid.UUID) error

RevokeAllUserTokens provides a mock function for the type AuthManager

type AuthManager_CreateNewPair_Call

type AuthManager_CreateNewPair_Call struct {
	*mock.Call
}

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

func (*AuthManager_CreateNewPair_Call) Return

func (*AuthManager_CreateNewPair_Call) Run

func (*AuthManager_CreateNewPair_Call) RunAndReturn

type AuthManager_Expecter

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

func (*AuthManager_Expecter) CreateNewPair

func (_e *AuthManager_Expecter) CreateNewPair(ctx interface{}, user interface{}) *AuthManager_CreateNewPair_Call

CreateNewPair is a helper method to define mock.On call

  • ctx context.Context
  • user models.User

func (*AuthManager_Expecter) Parse

func (_e *AuthManager_Expecter) Parse(tokenStr interface{}) *AuthManager_Parse_Call

Parse is a helper method to define mock.On call

  • tokenStr string

func (*AuthManager_Expecter) Refresh

func (_e *AuthManager_Expecter) Refresh(ctx interface{}, refreshToken interface{}) *AuthManager_Refresh_Call

Refresh is a helper method to define mock.On call

  • ctx context.Context
  • refreshToken string

func (*AuthManager_Expecter) RevokeAllUserTokens

func (_e *AuthManager_Expecter) RevokeAllUserTokens(ctx interface{}, userID interface{}) *AuthManager_RevokeAllUserTokens_Call

RevokeAllUserTokens is a helper method to define mock.On call

  • ctx context.Context
  • userID uuid.UUID

type AuthManager_Parse_Call

type AuthManager_Parse_Call struct {
	*mock.Call
}

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

func (*AuthManager_Parse_Call) Return

func (*AuthManager_Parse_Call) Run

func (_c *AuthManager_Parse_Call) Run(run func(tokenStr string)) *AuthManager_Parse_Call

func (*AuthManager_Parse_Call) RunAndReturn

func (_c *AuthManager_Parse_Call) RunAndReturn(run func(tokenStr string) (*auth.Claims, error)) *AuthManager_Parse_Call

type AuthManager_Refresh_Call

type AuthManager_Refresh_Call struct {
	*mock.Call
}

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

func (*AuthManager_Refresh_Call) Return

func (*AuthManager_Refresh_Call) Run

func (_c *AuthManager_Refresh_Call) Run(run func(ctx context.Context, refreshToken string)) *AuthManager_Refresh_Call

func (*AuthManager_Refresh_Call) RunAndReturn

func (_c *AuthManager_Refresh_Call) RunAndReturn(run func(ctx context.Context, refreshToken string) (*auth.TokenPair, error)) *AuthManager_Refresh_Call

type AuthManager_RevokeAllUserTokens_Call

type AuthManager_RevokeAllUserTokens_Call struct {
	*mock.Call
}

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

func (*AuthManager_RevokeAllUserTokens_Call) Return

func (*AuthManager_RevokeAllUserTokens_Call) Run

func (*AuthManager_RevokeAllUserTokens_Call) RunAndReturn

Jump to

Keyboard shortcuts

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