diff --git a/cmd/jaeger/internal/exporters/storageexporter/exporter_test.go b/cmd/jaeger/internal/exporters/storageexporter/exporter_test.go index d28131284cc..14f9ae29926 100644 --- a/cmd/jaeger/internal/exporters/storageexporter/exporter_test.go +++ b/cmd/jaeger/internal/exporters/storageexporter/exporter_test.go @@ -32,7 +32,7 @@ import ( type mockStorageExt struct { name string factory *factoryMocks.Factory - metricsFactory *factoryMocks.MetricsFactory + metricsFactory *factoryMocks.MetricStoreFactory } var _ jaegerstorage.Extension = (*mockStorageExt)(nil) diff --git a/plugin/metricstore/factory_test.go b/plugin/metricstore/factory_test.go index c3364d2a184..b0b2ca52ce0 100644 --- a/plugin/metricstore/factory_test.go +++ b/plugin/metricstore/factory_test.go @@ -69,7 +69,7 @@ func TestCreateMetricsReader(t *testing.T) { } type configurable struct { - mocks.MetricsFactory + mocks.MetricStoreFactory flagSet *flag.FlagSet viper *viper.Viper logger *zap.Logger diff --git a/storage/mocks/MetricsFactory.go b/storage/mocks/MetricStoreFactory.go similarity index 72% rename from storage/mocks/MetricsFactory.go rename to storage/mocks/MetricStoreFactory.go index a982dc1794e..1302a76e928 100644 --- a/storage/mocks/MetricsFactory.go +++ b/storage/mocks/MetricStoreFactory.go @@ -14,13 +14,13 @@ import ( telemetry "github.com/jaegertracing/jaeger/pkg/telemetry" ) -// MetricsFactory is an autogenerated mock type for the MetricsFactory type -type MetricsFactory struct { +// MetricStoreFactory is an autogenerated mock type for the MetricStoreFactory type +type MetricStoreFactory struct { mock.Mock } // CreateMetricsReader provides a mock function with given fields: -func (_m *MetricsFactory) CreateMetricsReader() (metricstore.Reader, error) { +func (_m *MetricStoreFactory) CreateMetricsReader() (metricstore.Reader, error) { ret := _m.Called() if len(ret) == 0 { @@ -50,7 +50,7 @@ func (_m *MetricsFactory) CreateMetricsReader() (metricstore.Reader, error) { } // Initialize provides a mock function with given fields: telset -func (_m *MetricsFactory) Initialize(telset telemetry.Settings) error { +func (_m *MetricStoreFactory) Initialize(telset telemetry.Settings) error { ret := _m.Called(telset) if len(ret) == 0 { @@ -67,13 +67,13 @@ func (_m *MetricsFactory) Initialize(telset telemetry.Settings) error { return r0 } -// NewMetricsFactory creates a new instance of MetricsFactory. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// NewMetricStoreFactory creates a new instance of MetricStoreFactory. 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 NewMetricsFactory(t interface { +func NewMetricStoreFactory(t interface { mock.TestingT Cleanup(func()) -}) *MetricsFactory { - mock := &MetricsFactory{} +}) *MetricStoreFactory { + mock := &MetricStoreFactory{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) })