testing

package
v0.30.2 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultTester = &Tester{}

Functions

This section is empty.

Types

type AgentTester added in v0.30.0

type AgentTester interface {
	ExpectAgentDialFailures(map[agent.DialFailureReason]int) error
	ExpectAgentDialFailure(agent.DialFailureReason, int) error
	ExpectAgentEndpointConnections(int) error
}

type ServerTester added in v0.30.0

type ServerTester interface {
	ExpectServerDialFailures(map[server.DialFailureReason]int) error
	ExpectServerDialFailure(server.DialFailureReason, int) error
	ExpectServerPendingDials(int) error
	ExpectServerReadyBackends(int) error
	ExpectServerEstablishedConns(int) error
}

type Tester added in v0.30.0

type Tester struct {
	// Endpoint is the metrics endpoint to scrape metrics from. If it is empty, the in-process
	// DefaultGatherer is used.
	Endpoint string
}

func (*Tester) ExpectAgentDialFailure added in v0.30.0

func (t *Tester) ExpectAgentDialFailure(reason agent.DialFailureReason, count int) error

func (*Tester) ExpectAgentDialFailures added in v0.30.0

func (t *Tester) ExpectAgentDialFailures(expected map[agent.DialFailureReason]int) error

func (*Tester) ExpectAgentEndpointConnections added in v0.30.0

func (t *Tester) ExpectAgentEndpointConnections(count int) error

func (*Tester) ExpectMetric added in v0.30.0

func (t *Tester) ExpectMetric(namespace, subsystem, name, expected string) error

func (*Tester) ExpectServerDialFailure added in v0.30.0

func (t *Tester) ExpectServerDialFailure(reason server.DialFailureReason, count int) error

func (*Tester) ExpectServerDialFailures added in v0.30.0

func (t *Tester) ExpectServerDialFailures(expected map[server.DialFailureReason]int) error

func (*Tester) ExpectServerEstablishedConns added in v0.30.0

func (t *Tester) ExpectServerEstablishedConns(v int) error

func (*Tester) ExpectServerPendingDials added in v0.30.0

func (t *Tester) ExpectServerPendingDials(v int) error

func (*Tester) ExpectServerReadyBackends added in v0.30.0

func (t *Tester) ExpectServerReadyBackends(v int) error

Jump to

Keyboard shortcuts

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