testing

package
v0.0.0-...-9f81391 Latest Latest
Warning

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

Go to latest
Published: May 3, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const EnvVarAcceptanceTests = "APPROZIUM_ACC"

Variables

This section is empty.

Functions

func ShouldRunAcceptanceTests

func ShouldRunAcceptanceTests() bool

func TestLogger

func TestLogger() *log.Logger

Types

type AwsEnv

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

This allows us to only get the signedGetCallerIdentity string once, but to reuse it throughout tests through the testEnv variable, reducing load on AWS.

func (*AwsEnv) ClaimedArn

func (e *AwsEnv) ClaimedArn() string

func (*AwsEnv) SignedGetCallerIdentity

func (e *AwsEnv) SignedGetCallerIdentity(t *testing.T) (string, error)

type TestResponseWriter

type TestResponseWriter struct {
	HeaderToReturn http.Header

	LastWriteInputReceived []byte
	WriteIntToReturn       int
	WriteErrToReturn       error

	LastStatusCodeReceived int
}

func (*TestResponseWriter) Header

func (t *TestResponseWriter) Header() http.Header

func (*TestResponseWriter) Write

func (t *TestResponseWriter) Write(input []byte) (int, error)

func (*TestResponseWriter) WriteHeader

func (t *TestResponseWriter) WriteHeader(statusCode int)

Jump to

Keyboard shortcuts

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