oidc_testing

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Jul 1, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider struct {
	IssuerTestSrv    *httptest.Server
	ExpectedRequests []Request
	// contains filtered or unexported fields
}

func (*Provider) MockDiscoveryCall

func (p *Provider) MockDiscoveryCall()

func (*Provider) MockPubKeysCall

func (p *Provider) MockPubKeysCall(jwkSetJSON []byte)

func (*Provider) MockTokenCall added in v0.2.0

func (p *Provider) MockTokenCall(statusCode int, token string)

func (*Provider) NewIDToken

func (p *Provider) NewIDToken(clientID string, subject string, nonce string, customClaims ...interface{}) (idToken string, jwkSetJSON []byte)

NewIDToken creates new token. Feel free to override basic claims in customClaim for various tests. NOTE: It is important that on every call we

func (*Provider) Setup

func (p *Provider) Setup(t *testing.T)

type Request added in v0.2.0

type Request struct {
	Method  string
	URL     string
	Handler func(http.ResponseWriter)
}

Jump to

Keyboard shortcuts

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