testcreds

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2019 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// InvalidCredsError is the error string returned when using MakeSecretWithInvalidCreds().
	InvalidCredsError = "unexpected end of JSON input"
)

Variables

View Source
var (
	// Secret is a reference to the Secret created by either MakeSecretWithCreds() and
	// MakeSecretWithInvalidCreds().
	Secret = &v1.ObjectReference{
		APIVersion: "v1",
		Kind:       "Secret",
		Namespace:  "secret-namespace",
		Name:       "secret-name",
	}

	// SecretKey is the key in the Secret data that contains the JSON credential token.
	SecretKey = "key.json"
)

Functions

func MakeSecretWithCreds

func MakeSecretWithCreds() *v1.Secret

MakeSecretWithCreds makes a Secret that can successfully be passed through GetCredentials. Only tests should be calling this.

func MakeSecretWithInvalidCreds

func MakeSecretWithInvalidCreds() *v1.Secret

MakeSecretWithInvalidCreds makes a Secret that fails to pass GetCredential. Only tests should be calling this.

Types

This section is empty.

Jump to

Keyboard shortcuts

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