mocks

package
v0.6.27 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

type Adapter struct {
	mock.Mock
}

Adapter is an autogenerated mock type for the Adapter type

func NewAdapter

func NewAdapter(t interface {
	mock.TestingT
	Cleanup(func())
}) *Adapter

NewAdapter creates a new instance of Adapter. 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 (*Adapter) CreateClient

func (_m *Adapter) CreateClient(ctx context.Context, options *models.DBOptions) interface{}

CreateClient provides a mock function with given fields: ctx, options

func (*Adapter) EXPECT

func (_m *Adapter) EXPECT() *Adapter_Expecter

type Adapter_CreateClient_Call

type Adapter_CreateClient_Call struct {
	*mock.Call
}

Adapter_CreateClient_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateClient'

func (*Adapter_CreateClient_Call) Return

func (_c *Adapter_CreateClient_Call) Return(_a0 interface{}) *Adapter_CreateClient_Call

func (*Adapter_CreateClient_Call) Run

func (*Adapter_CreateClient_Call) RunAndReturn

func (_c *Adapter_CreateClient_Call) RunAndReturn(run func(context.Context, *models.DBOptions) interface{}) *Adapter_CreateClient_Call

type Adapter_Expecter

type Adapter_Expecter struct {
	// contains filtered or unexported fields
}

func (*Adapter_Expecter) CreateClient

func (_e *Adapter_Expecter) CreateClient(ctx interface{}, options interface{}) *Adapter_CreateClient_Call

CreateClient is a helper method to define mock.On call

  • ctx context.Context
  • options *models.DBOptions

type Cache

type Cache struct {
	mock.Mock
}

Cache is an autogenerated mock type for the Cache type

func NewCache

func NewCache(t interface {
	mock.TestingT
	Cleanup(func())
}) *Cache

NewCache creates a new instance of Cache. 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 (*Cache) Clear

func (_m *Cache) Clear() error

Clear provides a mock function with given fields:

func (*Cache) Delete

func (_m *Cache) Delete(key string) error

Delete provides a mock function with given fields: key

func (*Cache) EXPECT

func (_m *Cache) EXPECT() *Cache_Expecter

func (*Cache) Get

func (_m *Cache) Get(key string) (interface{}, error)

Get provides a mock function with given fields: key

func (*Cache) Set

func (_m *Cache) Set(key string, value interface{}) error

Set provides a mock function with given fields: key, value

type Cache_Clear_Call

type Cache_Clear_Call struct {
	*mock.Call
}

Cache_Clear_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Clear'

func (*Cache_Clear_Call) Return

func (_c *Cache_Clear_Call) Return(_a0 error) *Cache_Clear_Call

func (*Cache_Clear_Call) Run

func (_c *Cache_Clear_Call) Run(run func()) *Cache_Clear_Call

func (*Cache_Clear_Call) RunAndReturn

func (_c *Cache_Clear_Call) RunAndReturn(run func() error) *Cache_Clear_Call

type Cache_Delete_Call

type Cache_Delete_Call struct {
	*mock.Call
}

Cache_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'

func (*Cache_Delete_Call) Return

func (_c *Cache_Delete_Call) Return(_a0 error) *Cache_Delete_Call

func (*Cache_Delete_Call) Run

func (_c *Cache_Delete_Call) Run(run func(key string)) *Cache_Delete_Call

func (*Cache_Delete_Call) RunAndReturn

func (_c *Cache_Delete_Call) RunAndReturn(run func(string) error) *Cache_Delete_Call

type Cache_Expecter

type Cache_Expecter struct {
	// contains filtered or unexported fields
}

func (*Cache_Expecter) Clear

func (_e *Cache_Expecter) Clear() *Cache_Clear_Call

Clear is a helper method to define mock.On call

func (*Cache_Expecter) Delete

func (_e *Cache_Expecter) Delete(key interface{}) *Cache_Delete_Call

Delete is a helper method to define mock.On call

  • key string

func (*Cache_Expecter) Get

func (_e *Cache_Expecter) Get(key interface{}) *Cache_Get_Call

Get is a helper method to define mock.On call

  • key string

func (*Cache_Expecter) Set

func (_e *Cache_Expecter) Set(key interface{}, value interface{}) *Cache_Set_Call

Set is a helper method to define mock.On call

  • key string
  • value interface{}

type Cache_Get_Call

type Cache_Get_Call struct {
	*mock.Call
}

Cache_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*Cache_Get_Call) Return

func (_c *Cache_Get_Call) Return(_a0 interface{}, _a1 error) *Cache_Get_Call

func (*Cache_Get_Call) Run

func (_c *Cache_Get_Call) Run(run func(key string)) *Cache_Get_Call

func (*Cache_Get_Call) RunAndReturn

func (_c *Cache_Get_Call) RunAndReturn(run func(string) (interface{}, error)) *Cache_Get_Call

type Cache_Set_Call

type Cache_Set_Call struct {
	*mock.Call
}

Cache_Set_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Set'

func (*Cache_Set_Call) Return

func (_c *Cache_Set_Call) Return(_a0 error) *Cache_Set_Call

func (*Cache_Set_Call) Run

func (_c *Cache_Set_Call) Run(run func(key string, value interface{})) *Cache_Set_Call

func (*Cache_Set_Call) RunAndReturn

func (_c *Cache_Set_Call) RunAndReturn(run func(string, interface{}) error) *Cache_Set_Call

type Logger

type Logger struct {
	mock.Mock
}

Logger is an autogenerated mock type for the Logger type

func NewLogger

func NewLogger(t interface {
	mock.TestingT
	Cleanup(func())
}) *Logger

NewLogger creates a new instance of Logger. 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 (*Logger) DPanic

func (_m *Logger) DPanic(args ...interface{})

DPanic provides a mock function with given fields: args

func (*Logger) DPanicf

func (_m *Logger) DPanicf(template string, args ...interface{})

DPanicf provides a mock function with given fields: template, args

func (*Logger) Debug

func (_m *Logger) Debug(args ...interface{})

Debug provides a mock function with given fields: args

func (*Logger) Debugf

func (_m *Logger) Debugf(template string, args ...interface{})

Debugf provides a mock function with given fields: template, args

func (*Logger) EXPECT

func (_m *Logger) EXPECT() *Logger_Expecter

func (*Logger) Error

func (_m *Logger) Error(args ...interface{})

Error provides a mock function with given fields: args

func (*Logger) Errorf

func (_m *Logger) Errorf(template string, args ...interface{})

Errorf provides a mock function with given fields: template, args

func (*Logger) Fatal

func (_m *Logger) Fatal(args ...interface{})

Fatal provides a mock function with given fields: args

func (*Logger) Fatalf

func (_m *Logger) Fatalf(template string, args ...interface{})

Fatalf provides a mock function with given fields: template, args

func (*Logger) Info

func (_m *Logger) Info(args ...interface{})

Info provides a mock function with given fields: args

func (*Logger) Infof

func (_m *Logger) Infof(template string, args ...interface{})

Infof provides a mock function with given fields: template, args

func (*Logger) InitLogger

func (_m *Logger) InitLogger(level string)

InitLogger provides a mock function with given fields: level

func (*Logger) Printf

func (_m *Logger) Printf(template string, args ...interface{})

Printf provides a mock function with given fields: template, args

func (*Logger) Warn

func (_m *Logger) Warn(args ...interface{})

Warn provides a mock function with given fields: args

func (*Logger) Warnf

func (_m *Logger) Warnf(template string, args ...interface{})

Warnf provides a mock function with given fields: template, args

type Logger_DPanic_Call

type Logger_DPanic_Call struct {
	*mock.Call
}

Logger_DPanic_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DPanic'

func (*Logger_DPanic_Call) Return

func (_c *Logger_DPanic_Call) Return() *Logger_DPanic_Call

func (*Logger_DPanic_Call) Run

func (_c *Logger_DPanic_Call) Run(run func(args ...interface{})) *Logger_DPanic_Call

func (*Logger_DPanic_Call) RunAndReturn

func (_c *Logger_DPanic_Call) RunAndReturn(run func(...interface{})) *Logger_DPanic_Call

type Logger_DPanicf_Call

type Logger_DPanicf_Call struct {
	*mock.Call
}

Logger_DPanicf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DPanicf'

func (*Logger_DPanicf_Call) Return

func (*Logger_DPanicf_Call) Run

func (_c *Logger_DPanicf_Call) Run(run func(template string, args ...interface{})) *Logger_DPanicf_Call

func (*Logger_DPanicf_Call) RunAndReturn

func (_c *Logger_DPanicf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_DPanicf_Call

type Logger_Debug_Call

type Logger_Debug_Call struct {
	*mock.Call
}

Logger_Debug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Debug'

func (*Logger_Debug_Call) Return

func (_c *Logger_Debug_Call) Return() *Logger_Debug_Call

func (*Logger_Debug_Call) Run

func (_c *Logger_Debug_Call) Run(run func(args ...interface{})) *Logger_Debug_Call

func (*Logger_Debug_Call) RunAndReturn

func (_c *Logger_Debug_Call) RunAndReturn(run func(...interface{})) *Logger_Debug_Call

type Logger_Debugf_Call

type Logger_Debugf_Call struct {
	*mock.Call
}

Logger_Debugf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Debugf'

func (*Logger_Debugf_Call) Return

func (_c *Logger_Debugf_Call) Return() *Logger_Debugf_Call

func (*Logger_Debugf_Call) Run

func (_c *Logger_Debugf_Call) Run(run func(template string, args ...interface{})) *Logger_Debugf_Call

func (*Logger_Debugf_Call) RunAndReturn

func (_c *Logger_Debugf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Debugf_Call

type Logger_Error_Call

type Logger_Error_Call struct {
	*mock.Call
}

Logger_Error_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Error'

func (*Logger_Error_Call) Return

func (_c *Logger_Error_Call) Return() *Logger_Error_Call

func (*Logger_Error_Call) Run

func (_c *Logger_Error_Call) Run(run func(args ...interface{})) *Logger_Error_Call

func (*Logger_Error_Call) RunAndReturn

func (_c *Logger_Error_Call) RunAndReturn(run func(...interface{})) *Logger_Error_Call

type Logger_Errorf_Call

type Logger_Errorf_Call struct {
	*mock.Call
}

Logger_Errorf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Errorf'

func (*Logger_Errorf_Call) Return

func (_c *Logger_Errorf_Call) Return() *Logger_Errorf_Call

func (*Logger_Errorf_Call) Run

func (_c *Logger_Errorf_Call) Run(run func(template string, args ...interface{})) *Logger_Errorf_Call

func (*Logger_Errorf_Call) RunAndReturn

func (_c *Logger_Errorf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Errorf_Call

type Logger_Expecter

type Logger_Expecter struct {
	// contains filtered or unexported fields
}

func (*Logger_Expecter) DPanic

func (_e *Logger_Expecter) DPanic(args ...interface{}) *Logger_DPanic_Call

DPanic is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) DPanicf

func (_e *Logger_Expecter) DPanicf(template interface{}, args ...interface{}) *Logger_DPanicf_Call

DPanicf is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) Debug

func (_e *Logger_Expecter) Debug(args ...interface{}) *Logger_Debug_Call

Debug is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) Debugf

func (_e *Logger_Expecter) Debugf(template interface{}, args ...interface{}) *Logger_Debugf_Call

Debugf is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) Error

func (_e *Logger_Expecter) Error(args ...interface{}) *Logger_Error_Call

Error is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) Errorf

func (_e *Logger_Expecter) Errorf(template interface{}, args ...interface{}) *Logger_Errorf_Call

Errorf is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) Fatal

func (_e *Logger_Expecter) Fatal(args ...interface{}) *Logger_Fatal_Call

Fatal is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) Fatalf

func (_e *Logger_Expecter) Fatalf(template interface{}, args ...interface{}) *Logger_Fatalf_Call

Fatalf is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) Info

func (_e *Logger_Expecter) Info(args ...interface{}) *Logger_Info_Call

Info is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) Infof

func (_e *Logger_Expecter) Infof(template interface{}, args ...interface{}) *Logger_Infof_Call

Infof is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) InitLogger

func (_e *Logger_Expecter) InitLogger(level interface{}) *Logger_InitLogger_Call

InitLogger is a helper method to define mock.On call

  • level string

func (*Logger_Expecter) Printf

func (_e *Logger_Expecter) Printf(template interface{}, args ...interface{}) *Logger_Printf_Call

Printf is a helper method to define mock.On call

  • template string
  • args ...interface{}

func (*Logger_Expecter) Warn

func (_e *Logger_Expecter) Warn(args ...interface{}) *Logger_Warn_Call

Warn is a helper method to define mock.On call

  • args ...interface{}

func (*Logger_Expecter) Warnf

func (_e *Logger_Expecter) Warnf(template interface{}, args ...interface{}) *Logger_Warnf_Call

Warnf is a helper method to define mock.On call

  • template string
  • args ...interface{}

type Logger_Fatal_Call

type Logger_Fatal_Call struct {
	*mock.Call
}

Logger_Fatal_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Fatal'

func (*Logger_Fatal_Call) Return

func (_c *Logger_Fatal_Call) Return() *Logger_Fatal_Call

func (*Logger_Fatal_Call) Run

func (_c *Logger_Fatal_Call) Run(run func(args ...interface{})) *Logger_Fatal_Call

func (*Logger_Fatal_Call) RunAndReturn

func (_c *Logger_Fatal_Call) RunAndReturn(run func(...interface{})) *Logger_Fatal_Call

type Logger_Fatalf_Call

type Logger_Fatalf_Call struct {
	*mock.Call
}

Logger_Fatalf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Fatalf'

func (*Logger_Fatalf_Call) Return

func (_c *Logger_Fatalf_Call) Return() *Logger_Fatalf_Call

func (*Logger_Fatalf_Call) Run

func (_c *Logger_Fatalf_Call) Run(run func(template string, args ...interface{})) *Logger_Fatalf_Call

func (*Logger_Fatalf_Call) RunAndReturn

func (_c *Logger_Fatalf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Fatalf_Call

type Logger_Info_Call

type Logger_Info_Call struct {
	*mock.Call
}

Logger_Info_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Info'

func (*Logger_Info_Call) Return

func (_c *Logger_Info_Call) Return() *Logger_Info_Call

func (*Logger_Info_Call) Run

func (_c *Logger_Info_Call) Run(run func(args ...interface{})) *Logger_Info_Call

func (*Logger_Info_Call) RunAndReturn

func (_c *Logger_Info_Call) RunAndReturn(run func(...interface{})) *Logger_Info_Call

type Logger_Infof_Call

type Logger_Infof_Call struct {
	*mock.Call
}

Logger_Infof_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Infof'

func (*Logger_Infof_Call) Return

func (_c *Logger_Infof_Call) Return() *Logger_Infof_Call

func (*Logger_Infof_Call) Run

func (_c *Logger_Infof_Call) Run(run func(template string, args ...interface{})) *Logger_Infof_Call

func (*Logger_Infof_Call) RunAndReturn

func (_c *Logger_Infof_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Infof_Call

type Logger_InitLogger_Call

type Logger_InitLogger_Call struct {
	*mock.Call
}

Logger_InitLogger_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InitLogger'

func (*Logger_InitLogger_Call) Return

func (*Logger_InitLogger_Call) Run

func (_c *Logger_InitLogger_Call) Run(run func(level string)) *Logger_InitLogger_Call

func (*Logger_InitLogger_Call) RunAndReturn

func (_c *Logger_InitLogger_Call) RunAndReturn(run func(string)) *Logger_InitLogger_Call

type Logger_Printf_Call

type Logger_Printf_Call struct {
	*mock.Call
}

Logger_Printf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Printf'

func (*Logger_Printf_Call) Return

func (_c *Logger_Printf_Call) Return() *Logger_Printf_Call

func (*Logger_Printf_Call) Run

func (_c *Logger_Printf_Call) Run(run func(template string, args ...interface{})) *Logger_Printf_Call

func (*Logger_Printf_Call) RunAndReturn

func (_c *Logger_Printf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Printf_Call

type Logger_Warn_Call

type Logger_Warn_Call struct {
	*mock.Call
}

Logger_Warn_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Warn'

func (*Logger_Warn_Call) Return

func (_c *Logger_Warn_Call) Return() *Logger_Warn_Call

func (*Logger_Warn_Call) Run

func (_c *Logger_Warn_Call) Run(run func(args ...interface{})) *Logger_Warn_Call

func (*Logger_Warn_Call) RunAndReturn

func (_c *Logger_Warn_Call) RunAndReturn(run func(...interface{})) *Logger_Warn_Call

type Logger_Warnf_Call

type Logger_Warnf_Call struct {
	*mock.Call
}

Logger_Warnf_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Warnf'

func (*Logger_Warnf_Call) Return

func (_c *Logger_Warnf_Call) Return() *Logger_Warnf_Call

func (*Logger_Warnf_Call) Run

func (_c *Logger_Warnf_Call) Run(run func(template string, args ...interface{})) *Logger_Warnf_Call

func (*Logger_Warnf_Call) RunAndReturn

func (_c *Logger_Warnf_Call) RunAndReturn(run func(string, ...interface{})) *Logger_Warnf_Call

Jump to

Keyboard shortcuts

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