mock

package
v0.0.0-...-f06bd48 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2022 License: MPL-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateAddEnvResAttributesMock

func CreateAddEnvResAttributesMock(retRes *resource.Resource, err error) func(res *resource.Resource, attributeMap map[string]string) (*resource.Resource, error)

CreateAddEnvResAttributesMock creates a mock implementation for utils/AddEnvResAttributes

func CreateGetServiceDetailsMock

func CreateGetServiceDetailsMock(attributes map[string]string) func() map[string]string

CreateGetServiceDetailsMock creates a mock implementation for utils/GetServiceDetails

Types

type DetectorMock

type DetectorMock struct {
	Res *resource.Resource
	Err error
}

DetectorMock mocks resource.Detector implementation

func (DetectorMock) Detect

func (detector DetectorMock) Detect(ctx context.Context) (*resource.Resource, error)

Detect detects a mocked resource

type LambdaMock

type LambdaMock struct {
	Output *sts.GetCallerIdentityOutput
	Err    error
}

LambdaMock mocks GetFunction behaviour of aws lambda sdk

func (LambdaMock) GetCallerIdentity

func (lm LambdaMock) GetCallerIdentity(input *sts.GetCallerIdentityInput) (*sts.GetCallerIdentityOutput, error)

GetFunction returns mocked lambda details

Jump to

Keyboard shortcuts

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