Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( InvalidJSONIdentifierError = errors.New("json: invalid identifier") UnknownJSONComparisonErr = errors.New("json: unknown comparison") )
View Source
var InvalidTargetTypeErr = errors.New("metric asserter: target is invalid numeric type")
View Source
var MissingMetadataErr = errors.New("metadata asserter: missing metadata")
View Source
var MissingMetricErr = errors.New("metric asserter: missing metric")
View Source
var NewJSON = func(config Config, logger *log.Logger) (Asserter, error) { return Asserter(&JSON{config, logger}), nil }
View Source
var NewMetadata = func(config Config, logger *log.Logger) (Asserter, error) { return Asserter(&Metadata{config, logger}), nil }
View Source
var NewMetric = func(config Config, logger *log.Logger) (Asserter, error) { return Asserter(&Metric{config, logger}), nil }
View Source
var NewText = func(config Config, logger *log.Logger) (Asserter, error) { return Asserter(&Text{config, logger}), nil }
View Source
var UnknownMetadataComparisonErr = errors.New("metadata asserter: unknown comparison")
View Source
var UnknownMetricComparisonErr = errors.New("metric asserter: unknown comparison")
View Source
var UnknownTextComparisonErr = errors.New("text asserter: unknown comparison")
Functions ¶
Types ¶
type Config ¶
type Config struct { // Source can be one of metric | metadata | json | text Source string `json:"source"` // Relevant name. e.g. metric name Identifier string `json:"identifier"` // Comparison type e.g. == | >= Comparison string `json:"comparison"` // Target value to compare against Target string `json:"target"` }
type JSON ¶
type JSON struct { Config // contains filtered or unexported fields }
func (*JSON) ValidateConfig ¶
type Metadata ¶
type Metadata struct { Config // contains filtered or unexported fields }
func (*Metadata) ValidateConfig ¶
type Metric ¶
type Metric struct { Config // contains filtered or unexported fields }
func (*Metric) ValidateConfig ¶
type Options ¶
type Options struct {
CheckResponse data.CheckResponse
}
Click to show internal directories.
Click to hide internal directories.