validation

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: May 13, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockNRDBClient

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

func NewMockNRDBClient

func NewMockNRDBClient() *MockNRDBClient

func (*MockNRDBClient) Attempts

func (c *MockNRDBClient) Attempts() int

func (*MockNRDBClient) QueryWithContext

func (c *MockNRDBClient) QueryWithContext(ctx context.Context, accountID int, nrql nrdb.NRQL) (*nrdb.NRDBResultContainer, error)

func (*MockNRDBClient) ReturnResultsAfterNAttempts

func (c *MockNRDBClient) ReturnResultsAfterNAttempts(before []nrdb.NRDBResult, after []nrdb.NRDBResult, attempts int)

func (*MockNRDBClient) ThrowError

func (c *MockNRDBClient) ThrowError(message string)

type MockRecipeValidator

type MockRecipeValidator struct {
	ValidateErrs      []error
	ValidateErr       error
	ValidateCallCount int
	ValidateVal       string
	ValidateVals      []string
}

func NewMockRecipeValidator

func NewMockRecipeValidator() *MockRecipeValidator

func (*MockRecipeValidator) ValidateRecipe added in v0.26.0

type PollingRecipeValidator

type PollingRecipeValidator struct {
	utilsValidation.PollingNRQLValidator
}

PollingRecipeValidator is an implementation of the RecipeValidator interface that polls NRDB to assert data is being reported for the given recipe.

func NewPollingRecipeValidator

func NewPollingRecipeValidator(c utils.NRDBClient) *PollingRecipeValidator

NewPollingRecipeValidator returns a new instance of PollingRecipeValidator.

func (*PollingRecipeValidator) ValidateRecipe added in v0.26.0

ValidateRecipe polls NRDB to assert data is being reported for the given recipe.

type RecipeValidator

type RecipeValidator interface {
	ValidateRecipe(context.Context, types.DiscoveryManifest, types.OpenInstallationRecipe) (entityGUID string, err error)
}

RecipeValidator validates installation of a recipe.

Jump to

Keyboard shortcuts

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