mocks

package
v0.0.0-...-165a0e8 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cfg

type Cfg struct {
	mock.Mock
}

Cfg is an autogenerated mock type for the cfg type

func NewCfg

func NewCfg(t interface {
	mock.TestingT
	Cleanup(func())
}) *Cfg

NewCfg creates a new instance of Cfg. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*Cfg) GetServerAddress

func (_m *Cfg) GetServerAddress() string

GetServerAddress provides a mock function with given fields:

func (*Cfg) GetStoreInterval

func (_m *Cfg) GetStoreInterval() time.Duration

GetStoreInterval provides a mock function with given fields:

type Storage

type Storage struct {
	mock.Mock
}

Storage is an autogenerated mock type for the storage type

func NewStorage

func NewStorage(t interface {
	mock.TestingT
	Cleanup(func())
}) *Storage

NewStorage creates a new instance of Storage. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*Storage) GetAllData

func (_m *Storage) GetAllData(ctx context.Context) (entity.MetricsType, error)

GetAllData provides a mock function with given fields: ctx

func (*Storage) GetCounter

func (_m *Storage) GetCounter(ctx context.Context, counterName string) (int64, error)

GetCounter provides a mock function with given fields: ctx, counterName

func (*Storage) GetGauge

func (_m *Storage) GetGauge(ctx context.Context, gaugeName string) (float64, error)

GetGauge provides a mock function with given fields: ctx, gaugeName

func (*Storage) Ping

func (_m *Storage) Ping(ctx context.Context) error

Ping provides a mock function with given fields: ctx

func (*Storage) SaveAllData

func (_m *Storage) SaveAllData(ctx context.Context, metrics []entity.Metrics) error

SaveAllData provides a mock function with given fields: ctx, metrics

func (*Storage) SaveCounter

func (_m *Storage) SaveCounter(ctx context.Context, counterName string, counterValue int64) error

SaveCounter provides a mock function with given fields: ctx, counterName, counterValue

func (*Storage) SaveGauge

func (_m *Storage) SaveGauge(ctx context.Context, gaugeName string, gaugeValue float64) error

SaveGauge provides a mock function with given fields: ctx, gaugeName, gaugeValue

Jump to

Keyboard shortcuts

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