Documentation
¶
Index ¶
- type Sender
- type SenderMock
- func (mmCount *SenderMock) Count(metric string, i int)
- func (mmCount *SenderMock) CountAfterCounter() uint64
- func (mmCount *SenderMock) CountBeforeCounter() uint64
- func (mmGauge *SenderMock) Gauge(metric string, n int)
- func (mmGauge *SenderMock) GaugeAfterCounter() uint64
- func (mmGauge *SenderMock) GaugeBeforeCounter() uint64
- func (mmGaugeMS *SenderMock) GaugeMS(metric string, t time.Time)
- func (mmGaugeMS *SenderMock) GaugeMSAfterCounter() uint64
- func (mmGaugeMS *SenderMock) GaugeMSBeforeCounter() uint64
- func (m *SenderMock) MinimockCountDone() bool
- func (m *SenderMock) MinimockCountInspect()
- func (m *SenderMock) MinimockFinish()
- func (m *SenderMock) MinimockGaugeDone() bool
- func (m *SenderMock) MinimockGaugeInspect()
- func (m *SenderMock) MinimockGaugeMSDone() bool
- func (m *SenderMock) MinimockGaugeMSInspect()
- func (m *SenderMock) MinimockWait(timeout mm_time.Duration)
- type SenderMockCountExpectation
- type SenderMockCountParams
- type SenderMockGaugeExpectation
- type SenderMockGaugeMSExpectation
- type SenderMockGaugeMSParams
- type SenderMockGaugeParams
- type Service
- type Statsd
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Sender ¶
type Sender interface { Count(metric string, i int) Gauge(metric string, n int) GaugeMS(metric string, t time.Time) }
A Sender is used to emit statsd type metrics.
type SenderMock ¶
type SenderMock struct { CountMock mSenderMockCount GaugeMock mSenderMockGauge GaugeMSMock mSenderMockGaugeMS // contains filtered or unexported fields }
SenderMock implements Sender
func NewSenderMock ¶
func NewSenderMock(t minimock.Tester) *SenderMock
NewSenderMock returns a mock for Sender
func (*SenderMock) Count ¶
func (mmCount *SenderMock) Count(metric string, i int)
Count implements Sender
func (*SenderMock) CountAfterCounter ¶
func (mmCount *SenderMock) CountAfterCounter() uint64
CountAfterCounter returns a count of finished SenderMock.Count invocations
func (*SenderMock) CountBeforeCounter ¶
func (mmCount *SenderMock) CountBeforeCounter() uint64
CountBeforeCounter returns a count of SenderMock.Count invocations
func (*SenderMock) Gauge ¶
func (mmGauge *SenderMock) Gauge(metric string, n int)
Gauge implements Sender
func (*SenderMock) GaugeAfterCounter ¶
func (mmGauge *SenderMock) GaugeAfterCounter() uint64
GaugeAfterCounter returns a count of finished SenderMock.Gauge invocations
func (*SenderMock) GaugeBeforeCounter ¶
func (mmGauge *SenderMock) GaugeBeforeCounter() uint64
GaugeBeforeCounter returns a count of SenderMock.Gauge invocations
func (*SenderMock) GaugeMS ¶
func (mmGaugeMS *SenderMock) GaugeMS(metric string, t time.Time)
GaugeMS implements Sender
func (*SenderMock) GaugeMSAfterCounter ¶
func (mmGaugeMS *SenderMock) GaugeMSAfterCounter() uint64
GaugeMSAfterCounter returns a count of finished SenderMock.GaugeMS invocations
func (*SenderMock) GaugeMSBeforeCounter ¶
func (mmGaugeMS *SenderMock) GaugeMSBeforeCounter() uint64
GaugeMSBeforeCounter returns a count of SenderMock.GaugeMS invocations
func (*SenderMock) MinimockCountDone ¶
func (m *SenderMock) MinimockCountDone() bool
MinimockCountDone returns true if the count of the Count invocations corresponds the number of defined expectations
func (*SenderMock) MinimockCountInspect ¶
func (m *SenderMock) MinimockCountInspect()
MinimockCountInspect logs each unmet expectation
func (*SenderMock) MinimockFinish ¶
func (m *SenderMock) MinimockFinish()
MinimockFinish checks that all mocked methods have been called the expected number of times
func (*SenderMock) MinimockGaugeDone ¶
func (m *SenderMock) MinimockGaugeDone() bool
MinimockGaugeDone returns true if the count of the Gauge invocations corresponds the number of defined expectations
func (*SenderMock) MinimockGaugeInspect ¶
func (m *SenderMock) MinimockGaugeInspect()
MinimockGaugeInspect logs each unmet expectation
func (*SenderMock) MinimockGaugeMSDone ¶
func (m *SenderMock) MinimockGaugeMSDone() bool
MinimockGaugeMSDone returns true if the count of the GaugeMS invocations corresponds the number of defined expectations
func (*SenderMock) MinimockGaugeMSInspect ¶
func (m *SenderMock) MinimockGaugeMSInspect()
MinimockGaugeMSInspect logs each unmet expectation
func (*SenderMock) MinimockWait ¶
func (m *SenderMock) MinimockWait(timeout mm_time.Duration)
MinimockWait waits for all mocked methods to be called the expected number of times
type SenderMockCountExpectation ¶
type SenderMockCountExpectation struct { Counter uint64 // contains filtered or unexported fields }
SenderMockCountExpectation specifies expectation struct of the Sender.Count
type SenderMockCountParams ¶
type SenderMockCountParams struct {
// contains filtered or unexported fields
}
SenderMockCountParams contains parameters of the Sender.Count
type SenderMockGaugeExpectation ¶
type SenderMockGaugeExpectation struct { Counter uint64 // contains filtered or unexported fields }
SenderMockGaugeExpectation specifies expectation struct of the Sender.Gauge
type SenderMockGaugeMSExpectation ¶
type SenderMockGaugeMSExpectation struct { Counter uint64 // contains filtered or unexported fields }
SenderMockGaugeMSExpectation specifies expectation struct of the Sender.GaugeMS
type SenderMockGaugeMSParams ¶
type SenderMockGaugeMSParams struct {
// contains filtered or unexported fields
}
SenderMockGaugeMSParams contains parameters of the Sender.GaugeMS
type SenderMockGaugeParams ¶
type SenderMockGaugeParams struct {
// contains filtered or unexported fields
}
SenderMockGaugeParams contains parameters of the Sender.Gauge
type Statsd ¶
type Statsd struct {
Agent netservice.Instance `json:"agent"`
}