@ -5,144 +5,121 @@
package mock_config
package mock_config
import (
import (
reflect "reflect"
models "github.com/analogj/scrutiny/collector/pkg/models"
models "github.com/analogj/scrutiny/collector/pkg/models"
gomock "github.com/golang/mock/gomock"
gomock "github.com/golang/mock/gomock"
viper "github.com/spf13/viper"
viper "github.com/spf13/viper"
reflect "reflect"
)
)
// MockInterface is a mock of Interface interface
// MockInterface is a mock of Interface interface .
type MockInterface struct {
type MockInterface struct {
ctrl * gomock . Controller
ctrl * gomock . Controller
recorder * MockInterfaceMockRecorder
recorder * MockInterfaceMockRecorder
}
}
// MockInterfaceMockRecorder is the mock recorder for MockInterface
// MockInterfaceMockRecorder is the mock recorder for MockInterface .
type MockInterfaceMockRecorder struct {
type MockInterfaceMockRecorder struct {
mock * MockInterface
mock * MockInterface
}
}
// NewMockInterface creates a new mock instance
// NewMockInterface creates a new mock instance .
func NewMockInterface ( ctrl * gomock . Controller ) * MockInterface {
func NewMockInterface ( ctrl * gomock . Controller ) * MockInterface {
mock := & MockInterface { ctrl : ctrl }
mock := & MockInterface { ctrl : ctrl }
mock . recorder = & MockInterfaceMockRecorder { mock }
mock . recorder = & MockInterfaceMockRecorder { mock }
return mock
return mock
}
}
// EXPECT returns an object that allows the caller to indicate expected use
// EXPECT returns an object that allows the caller to indicate expected use .
func ( m * MockInterface ) EXPECT ( ) * MockInterfaceMockRecorder {
func ( m * MockInterface ) EXPECT ( ) * MockInterfaceMockRecorder {
return m . recorder
return m . recorder
}
}
// Init mocks base method
// AllSettings mocks base method.
func ( m * MockInterface ) Init( ) error {
func ( m * MockInterface ) AllSettings( ) map [ string ] interface { } {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , " Init ")
ret := m . ctrl . Call ( m , " AllSettings ")
ret0 , _ := ret [ 0 ] . ( error )
ret0 , _ := ret [ 0 ] . ( map [ string ] interface { } )
return ret0
return ret0
}
}
// Init indicates an expected call of Init
// AllSettings indicates an expected call of AllSettings.
func ( mr * MockInterfaceMockRecorder ) Init ( ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) AllSettings ( ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " Init ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . Init ) )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " AllSettings ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . AllSettings ) )
}
}
// ReadConfig mocks base method
// Get mocks base method.
func ( m * MockInterface ) ReadConfig( configFilePath string ) error {
func ( m * MockInterface ) Get( key string ) interface { } {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , " ReadConfig", configFilePath )
ret := m . ctrl . Call ( m , " Get", key )
ret0 , _ := ret [ 0 ] . ( error )
ret0 , _ := ret [ 0 ] . ( interface { } )
return ret0
return ret0
}
}
// ReadConfig indicates an expected call of ReadConfig
// Get indicates an expected call of Get.
func ( mr * MockInterfaceMockRecorder ) ReadConfig ( configFilePath interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) Get ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "ReadConfig" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . ReadConfig ) , configFilePath )
}
// Set mocks base method
func ( m * MockInterface ) Set ( key string , value interface { } ) {
m . ctrl . T . Helper ( )
m . ctrl . Call ( m , "Set" , key , value )
}
// Set indicates an expected call of Set
func ( mr * MockInterfaceMockRecorder ) Set ( key , value interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Set" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . Set ) , key , value )
}
// SetDefault mocks base method
func ( m * MockInterface ) SetDefault ( key string , value interface { } ) {
m . ctrl . T . Helper ( )
m . ctrl . Call ( m , "SetDefault" , key , value )
}
// SetDefault indicates an expected call of SetDefault
func ( mr * MockInterfaceMockRecorder ) SetDefault ( key , value interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " SetDefaul t", reflect . TypeOf ( ( * MockInterface ) ( nil ) . SetDefault) , key , value )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Get" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . Get ) , key )
}
}
// AllSettings mocks base method
// GetBool mocks base method.
func ( m * MockInterface ) AllSettings( ) map [ string ] interface { } {
func ( m * MockInterface ) GetBool ( key string ) bool {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , " AllSettings" )
ret := m . ctrl . Call ( m , "GetBool" , key )
ret0 , _ := ret [ 0 ] . ( map [ string ] interface { } )
ret0 , _ := ret [ 0 ] . ( bool )
return ret0
return ret0
}
}
// AllSettings indicates an expected call of AllSettings
// GetBool indicates an expected call of GetBool.
func ( mr * MockInterfaceMockRecorder ) AllSettings( ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) GetBool ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " AllSettings ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . AllSettings) )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetBool" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetBool ) , key )
}
}
// IsSet mocks base method
// GetCommandMetricsInfoArgs mocks base method.
func ( m * MockInterface ) IsSet( key string ) bool {
func ( m * MockInterface ) GetCommandMetricsInfoArgs ( deviceName string ) string {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , " IsSet", key )
ret := m . ctrl . Call ( m , "GetCommandMetricsInfoArgs" , deviceName )
ret0 , _ := ret [ 0 ] . ( bool )
ret0 , _ := ret [ 0 ] . ( string )
return ret0
return ret0
}
}
// IsSet indicates an expected call of IsSet
// GetCommandMetricsInfoArgs indicates an expected call of GetCommandMetricsInfoArgs.
func ( mr * MockInterfaceMockRecorder ) IsSet( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) GetCommandMetricsInfoArgs( deviceName interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " IsSet ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . IsSet) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , " GetCommandMetricsInfoArgs ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetCommandMetricsInfoArgs) , deviceName )
}
}
// Get mocks base method
// Get CommandMetricsSmartArgs mocks base method.
func ( m * MockInterface ) Get ( key string ) interface { } {
func ( m * MockInterface ) Get CommandMetricsSmartArgs( deviceName string ) string {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "Get ", key )
ret := m . ctrl . Call ( m , "Get CommandMetricsSmartArgs", deviceName )
ret0 , _ := ret [ 0 ] . ( interface { } )
ret0 , _ := ret [ 0 ] . ( string )
return ret0
return ret0
}
}
// Get indicates an expected call of Get
// Get CommandMetricsSmartArgs indicates an expected call of GetCommandMetricsSmartArgs.
func ( mr * MockInterfaceMockRecorder ) Get ( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) Get CommandMetricsSmartArgs( deviceName interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Get ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . Get ) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Get CommandMetricsSmartArgs ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . Get CommandMetricsSmartArgs) , deviceName )
}
}
// Get Bool mocks base method
// Get DeviceOverrides mocks base method.
func ( m * MockInterface ) Get Bool( key string ) bool {
func ( m * MockInterface ) Get DeviceOverrides( ) [ ] models . ScanOverride {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "Get Bool", key )
ret := m . ctrl . Call ( m , "Get DeviceOverrides" )
ret0 , _ := ret [ 0 ] . ( bool )
ret0 , _ := ret [ 0 ] . ( [ ] models . ScanOverride )
return ret0
return ret0
}
}
// Get Bool indicates an expected call of GetBool
// Get DeviceOverrides indicates an expected call of GetDeviceOverrides.
func ( mr * MockInterfaceMockRecorder ) Get Bool( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) Get DeviceOverrides( ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Get Bool ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . Get Bool) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Get DeviceOverrides ", reflect . TypeOf ( ( * MockInterface ) ( nil ) . Get DeviceOverrides) )
}
}
// GetInt mocks base method
// GetInt mocks base method .
func ( m * MockInterface ) GetInt ( key string ) int {
func ( m * MockInterface ) GetInt ( key string ) int {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "GetInt" , key )
ret := m . ctrl . Call ( m , "GetInt" , key )
@ -150,13 +127,13 @@ func (m *MockInterface) GetInt(key string) int {
return ret0
return ret0
}
}
// GetInt indicates an expected call of GetInt
// GetInt indicates an expected call of GetInt .
func ( mr * MockInterfaceMockRecorder ) GetInt ( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) GetInt ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetInt" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetInt ) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetInt" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetInt ) , key )
}
}
// GetString mocks base method
// GetString mocks base method .
func ( m * MockInterface ) GetString ( key string ) string {
func ( m * MockInterface ) GetString ( key string ) string {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "GetString" , key )
ret := m . ctrl . Call ( m , "GetString" , key )
@ -164,13 +141,13 @@ func (m *MockInterface) GetString(key string) string {
return ret0
return ret0
}
}
// GetString indicates an expected call of GetString
// GetString indicates an expected call of GetString .
func ( mr * MockInterfaceMockRecorder ) GetString ( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) GetString ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetString" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetString ) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetString" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetString ) , key )
}
}
// GetStringSlice mocks base method
// GetStringSlice mocks base method .
func ( m * MockInterface ) GetStringSlice ( key string ) [ ] string {
func ( m * MockInterface ) GetStringSlice ( key string ) [ ] string {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "GetStringSlice" , key )
ret := m . ctrl . Call ( m , "GetStringSlice" , key )
@ -178,13 +155,79 @@ func (m *MockInterface) GetStringSlice(key string) []string {
return ret0
return ret0
}
}
// GetStringSlice indicates an expected call of GetStringSlice
// GetStringSlice indicates an expected call of GetStringSlice .
func ( mr * MockInterfaceMockRecorder ) GetStringSlice ( key interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) GetStringSlice ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetStringSlice" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetStringSlice ) , key )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetStringSlice" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetStringSlice ) , key )
}
}
// UnmarshalKey mocks base method
// Init mocks base method.
func ( m * MockInterface ) Init ( ) error {
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "Init" )
ret0 , _ := ret [ 0 ] . ( error )
return ret0
}
// Init indicates an expected call of Init.
func ( mr * MockInterfaceMockRecorder ) Init ( ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Init" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . Init ) )
}
// IsSet mocks base method.
func ( m * MockInterface ) IsSet ( key string ) bool {
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "IsSet" , key )
ret0 , _ := ret [ 0 ] . ( bool )
return ret0
}
// IsSet indicates an expected call of IsSet.
func ( mr * MockInterfaceMockRecorder ) IsSet ( key interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "IsSet" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . IsSet ) , key )
}
// ReadConfig mocks base method.
func ( m * MockInterface ) ReadConfig ( configFilePath string ) error {
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "ReadConfig" , configFilePath )
ret0 , _ := ret [ 0 ] . ( error )
return ret0
}
// ReadConfig indicates an expected call of ReadConfig.
func ( mr * MockInterfaceMockRecorder ) ReadConfig ( configFilePath interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "ReadConfig" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . ReadConfig ) , configFilePath )
}
// Set mocks base method.
func ( m * MockInterface ) Set ( key string , value interface { } ) {
m . ctrl . T . Helper ( )
m . ctrl . Call ( m , "Set" , key , value )
}
// Set indicates an expected call of Set.
func ( mr * MockInterfaceMockRecorder ) Set ( key , value interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "Set" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . Set ) , key , value )
}
// SetDefault mocks base method.
func ( m * MockInterface ) SetDefault ( key string , value interface { } ) {
m . ctrl . T . Helper ( )
m . ctrl . Call ( m , "SetDefault" , key , value )
}
// SetDefault indicates an expected call of SetDefault.
func ( mr * MockInterfaceMockRecorder ) SetDefault ( key , value interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "SetDefault" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . SetDefault ) , key , value )
}
// UnmarshalKey mocks base method.
func ( m * MockInterface ) UnmarshalKey ( key string , rawVal interface { } , decoderOpts ... viper . DecoderConfigOption ) error {
func ( m * MockInterface ) UnmarshalKey ( key string , rawVal interface { } , decoderOpts ... viper . DecoderConfigOption ) error {
m . ctrl . T . Helper ( )
m . ctrl . T . Helper ( )
varargs := [ ] interface { } { key , rawVal }
varargs := [ ] interface { } { key , rawVal }
@ -196,23 +239,9 @@ func (m *MockInterface) UnmarshalKey(key string, rawVal interface{}, decoderOpts
return ret0
return ret0
}
}
// UnmarshalKey indicates an expected call of UnmarshalKey
// UnmarshalKey indicates an expected call of UnmarshalKey .
func ( mr * MockInterfaceMockRecorder ) UnmarshalKey ( key , rawVal interface { } , decoderOpts ... interface { } ) * gomock . Call {
func ( mr * MockInterfaceMockRecorder ) UnmarshalKey ( key , rawVal interface { } , decoderOpts ... interface { } ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
mr . mock . ctrl . T . Helper ( )
varargs := append ( [ ] interface { } { key , rawVal } , decoderOpts ... )
varargs := append ( [ ] interface { } { key , rawVal } , decoderOpts ... )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "UnmarshalKey" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . UnmarshalKey ) , varargs ... )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "UnmarshalKey" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . UnmarshalKey ) , varargs ... )
}
}
// GetScanOverrides mocks base method
func ( m * MockInterface ) GetScanOverrides ( ) [ ] models . ScanOverride {
m . ctrl . T . Helper ( )
ret := m . ctrl . Call ( m , "GetScanOverrides" )
ret0 , _ := ret [ 0 ] . ( [ ] models . ScanOverride )
return ret0
}
// GetScanOverrides indicates an expected call of GetScanOverrides
func ( mr * MockInterfaceMockRecorder ) GetScanOverrides ( ) * gomock . Call {
mr . mock . ctrl . T . Helper ( )
return mr . mock . ctrl . RecordCallWithMethodType ( mr . mock , "GetScanOverrides" , reflect . TypeOf ( ( * MockInterface ) ( nil ) . GetScanOverrides ) )
}