mocks

package
v0.0.0-...-e080771 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessTokenVerifier

type AccessTokenVerifier struct {
	mock.Mock
}

AccessTokenVerifier is an autogenerated mock type for the AccessTokenVerifier type

func (*AccessTokenVerifier) Verify

func (_m *AccessTokenVerifier) Verify(accessToken string) (*authentication.UserProfile, error)

Verify provides a mock function with given fields: accessToken

type OAuth2Config

type OAuth2Config struct {
	mock.Mock
}

OAuth2Config is an autogenerated mock type for the OAuth2Config type

func (*OAuth2Config) AuthCodeURL

func (_m *OAuth2Config) AuthCodeURL(state string, opts ...oauth2.AuthCodeOption) string

AuthCodeURL provides a mock function with given fields: state, opts

func (*OAuth2Config) Client

func (_m *OAuth2Config) Client(ctx context.Context, t *oauth2.Token) *http.Client

Client provides a mock function with given fields: ctx, t

func (*OAuth2Config) Exchange

func (_m *OAuth2Config) Exchange(ctx context.Context, code string, opts ...oauth2.AuthCodeOption) (*oauth2.Token, error)

Exchange provides a mock function with given fields: ctx, code, opts

func (*OAuth2Config) PasswordCredentialsToken

func (_m *OAuth2Config) PasswordCredentialsToken(ctx context.Context, username string, password string) (*oauth2.Token, error)

PasswordCredentialsToken provides a mock function with given fields: ctx, username, password

func (*OAuth2Config) TokenSource

func (_m *OAuth2Config) TokenSource(ctx context.Context, t *oauth2.Token) oauth2.TokenSource

TokenSource provides a mock function with given fields: ctx, t

type UserResolver

type UserResolver struct {
	mock.Mock
}

UserResolver is an autogenerated mock type for the UserResolver type

func NewUserResolver

func NewUserResolver(t mockConstructorTestingTNewUserResolver) *UserResolver

NewUserResolver creates a new instance of UserResolver. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*UserResolver) GetOrCreateUser

func (_m *UserResolver) GetOrCreateUser(username string, email string, firstname string, lastname string, isAdmin bool) (*service.UserModel, error)

GetOrCreateUser provides a mock function with given fields: username, email, firstname, lastname, isAdmin

Jump to

Keyboard shortcuts

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