mocks

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2026 License: GPL-3.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 MockAuthenticator

type MockAuthenticator struct {
	mock.Mock
}

MockAuthenticator is an autogenerated mock type for the Authenticator type

func NewMockAuthenticator

func NewMockAuthenticator(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockAuthenticator

NewMockAuthenticator creates a new instance of MockAuthenticator. 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 (*MockAuthenticator) EXPECT

func (*MockAuthenticator) TouchSessionAsync

func (_m *MockAuthenticator) TouchSessionAsync(jti string)

TouchSessionAsync provides a mock function with given fields: jti

func (*MockAuthenticator) ValidateAPIKey

func (_m *MockAuthenticator) ValidateAPIKey(ctx context.Context, key string) (*ent.User, error)

ValidateAPIKey provides a mock function with given fields: ctx, key

func (*MockAuthenticator) ValidateSession

func (_m *MockAuthenticator) ValidateSession(ctx context.Context, jti string) error

ValidateSession provides a mock function with given fields: ctx, jti

func (*MockAuthenticator) ValidateToken

func (_m *MockAuthenticator) ValidateToken(token string) (*auth.Claims, error)

ValidateToken provides a mock function with given fields: token

type MockAuthenticator_Expecter

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

func (*MockAuthenticator_Expecter) TouchSessionAsync

func (_e *MockAuthenticator_Expecter) TouchSessionAsync(jti interface{}) *MockAuthenticator_TouchSessionAsync_Call

TouchSessionAsync is a helper method to define mock.On call

  • jti string

func (*MockAuthenticator_Expecter) ValidateAPIKey

func (_e *MockAuthenticator_Expecter) ValidateAPIKey(ctx interface{}, key interface{}) *MockAuthenticator_ValidateAPIKey_Call

ValidateAPIKey is a helper method to define mock.On call

  • ctx context.Context
  • key string

func (*MockAuthenticator_Expecter) ValidateSession

func (_e *MockAuthenticator_Expecter) ValidateSession(ctx interface{}, jti interface{}) *MockAuthenticator_ValidateSession_Call

ValidateSession is a helper method to define mock.On call

  • ctx context.Context
  • jti string

func (*MockAuthenticator_Expecter) ValidateToken

func (_e *MockAuthenticator_Expecter) ValidateToken(token interface{}) *MockAuthenticator_ValidateToken_Call

ValidateToken is a helper method to define mock.On call

  • token string

type MockAuthenticator_TouchSessionAsync_Call

type MockAuthenticator_TouchSessionAsync_Call struct {
	*mock.Call
}

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

func (*MockAuthenticator_TouchSessionAsync_Call) Return

func (*MockAuthenticator_TouchSessionAsync_Call) Run

func (*MockAuthenticator_TouchSessionAsync_Call) RunAndReturn

type MockAuthenticator_ValidateAPIKey_Call

type MockAuthenticator_ValidateAPIKey_Call struct {
	*mock.Call
}

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

func (*MockAuthenticator_ValidateAPIKey_Call) Return

func (*MockAuthenticator_ValidateAPIKey_Call) Run

func (*MockAuthenticator_ValidateAPIKey_Call) RunAndReturn

type MockAuthenticator_ValidateSession_Call

type MockAuthenticator_ValidateSession_Call struct {
	*mock.Call
}

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

func (*MockAuthenticator_ValidateSession_Call) Return

func (*MockAuthenticator_ValidateSession_Call) Run

func (*MockAuthenticator_ValidateSession_Call) RunAndReturn

type MockAuthenticator_ValidateToken_Call

type MockAuthenticator_ValidateToken_Call struct {
	*mock.Call
}

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

func (*MockAuthenticator_ValidateToken_Call) Return

func (*MockAuthenticator_ValidateToken_Call) Run

func (*MockAuthenticator_ValidateToken_Call) RunAndReturn

Jump to

Keyboard shortcuts

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