mocks

package
v0.0.0-...-5aa5535 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 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 DataItem

type DataItem struct {
	mock.Mock
}

DataItem is an autogenerated mock type for the DataItem type

func NewDataItem

func NewDataItem(t mockConstructorTestingTNewDataItem) *DataItem

NewDataItem creates a new instance of DataItem. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*DataItem) EXPECT

func (_m *DataItem) EXPECT() *DataItem_Expecter

type DataItem_Expecter

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

type Store

type Store struct {
	mock.Mock
}

Store is an autogenerated mock type for the Store type

func NewStore

func NewStore(t mockConstructorTestingTNewStore) *Store

NewStore creates a new instance of Store. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*Store) AddRecords

func (_m *Store) AddRecords(ctx context.Context, topic string, records ...*models.Record) error

AddRecords provides a mock function with given fields: ctx, topic, records

func (*Store) Close

func (_m *Store) Close()

Close provides a mock function with given fields:

func (*Store) CommitConsumerPosition

func (_m *Store) CommitConsumerPosition(ctx context.Context, consumer *models.Consumer) error

CommitConsumerPosition provides a mock function with given fields: ctx, consumer

func (*Store) CreateTopic

func (_m *Store) CreateTopic(ctx context.Context, topic *models.Topic) error

CreateTopic provides a mock function with given fields: ctx, topic

func (*Store) DeleteTopic

func (_m *Store) DeleteTopic(ctx context.Context, topic *models.Topic) error

DeleteTopic provides a mock function with given fields: ctx, topic

func (*Store) EXPECT

func (_m *Store) EXPECT() *Store_Expecter

func (*Store) FetchRecord

func (_m *Store) FetchRecord(ctx context.Context, consumer *models.Consumer) (*models.Record, error)

FetchRecord provides a mock function with given fields: ctx, consumer

func (*Store) GetConsumerLag

func (_m *Store) GetConsumerLag(ctx context.Context, consumer *models.Consumer) (int64, error)

GetConsumerLag provides a mock function with given fields: ctx, consumer

func (*Store) GetConsumerPosition

func (_m *Store) GetConsumerPosition(ctx context.Context, consumer *models.Consumer) (string, error)

GetConsumerPosition provides a mock function with given fields: ctx, consumer

func (*Store) GetRecords

func (_m *Store) GetRecords(ctx context.Context, topic string, start string, limit int) ([]*models.Record, error)

GetRecords provides a mock function with given fields: ctx, topic, start, limit

func (*Store) Impl

func (_m *Store) Impl() interface{}

Impl provides a mock function with given fields:

func (*Store) ListTopics

func (_m *Store) ListTopics(ctx context.Context) ([]string, error)

ListTopics provides a mock function with given fields: ctx

func (*Store) LoadMeta

func (_m *Store) LoadMeta(ctx context.Context, topic string) (*models.Topic, error)

LoadMeta provides a mock function with given fields: ctx, topic

func (*Store) PruneOldRecords

func (_m *Store) PruneOldRecords(ctx context.Context) error

PruneOldRecords provides a mock function with given fields: ctx

func (*Store) RegisterConsumer

func (_m *Store) RegisterConsumer(ctx context.Context, consumer *models.Consumer) (*models.Consumer, error)

RegisterConsumer provides a mock function with given fields: ctx, consumer

func (*Store) SnapshotItems

func (_m *Store) SnapshotItems() <-chan store.DataItem

SnapshotItems provides a mock function with given fields:

func (*Store) Stats

func (_m *Store) Stats() map[string]*models.Topic

Stats provides a mock function with given fields:

type Store_AddRecords_Call

type Store_AddRecords_Call struct {
	*mock.Call
}

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

func (*Store_AddRecords_Call) Return

func (*Store_AddRecords_Call) Run

func (_c *Store_AddRecords_Call) Run(run func(ctx context.Context, topic string, records ...*models.Record)) *Store_AddRecords_Call

func (*Store_AddRecords_Call) RunAndReturn

type Store_Close_Call

type Store_Close_Call struct {
	*mock.Call
}

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

func (*Store_Close_Call) Return

func (_c *Store_Close_Call) Return() *Store_Close_Call

func (*Store_Close_Call) Run

func (_c *Store_Close_Call) Run(run func()) *Store_Close_Call

func (*Store_Close_Call) RunAndReturn

func (_c *Store_Close_Call) RunAndReturn(run func()) *Store_Close_Call

type Store_CommitConsumerPosition_Call

type Store_CommitConsumerPosition_Call struct {
	*mock.Call
}

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

func (*Store_CommitConsumerPosition_Call) Return

func (*Store_CommitConsumerPosition_Call) Run

func (*Store_CommitConsumerPosition_Call) RunAndReturn

type Store_CreateTopic_Call

type Store_CreateTopic_Call struct {
	*mock.Call
}

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

func (*Store_CreateTopic_Call) Return

func (*Store_CreateTopic_Call) Run

func (_c *Store_CreateTopic_Call) Run(run func(ctx context.Context, topic *models.Topic)) *Store_CreateTopic_Call

func (*Store_CreateTopic_Call) RunAndReturn

type Store_DeleteTopic_Call

type Store_DeleteTopic_Call struct {
	*mock.Call
}

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

func (*Store_DeleteTopic_Call) Return

func (*Store_DeleteTopic_Call) Run

func (_c *Store_DeleteTopic_Call) Run(run func(ctx context.Context, topic *models.Topic)) *Store_DeleteTopic_Call

func (*Store_DeleteTopic_Call) RunAndReturn

type Store_Expecter

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

func (*Store_Expecter) AddRecords

func (_e *Store_Expecter) AddRecords(ctx interface{}, topic interface{}, records ...interface{}) *Store_AddRecords_Call

AddRecords is a helper method to define mock.On call

  • ctx context.Context
  • topic string
  • records ...*models.Record

func (*Store_Expecter) Close

func (_e *Store_Expecter) Close() *Store_Close_Call

Close is a helper method to define mock.On call

func (*Store_Expecter) CommitConsumerPosition

func (_e *Store_Expecter) CommitConsumerPosition(ctx interface{}, consumer interface{}) *Store_CommitConsumerPosition_Call

CommitConsumerPosition is a helper method to define mock.On call

  • ctx context.Context
  • consumer *models.Consumer

func (*Store_Expecter) CreateTopic

func (_e *Store_Expecter) CreateTopic(ctx interface{}, topic interface{}) *Store_CreateTopic_Call

CreateTopic is a helper method to define mock.On call

  • ctx context.Context
  • topic *models.Topic

func (*Store_Expecter) DeleteTopic

func (_e *Store_Expecter) DeleteTopic(ctx interface{}, topic interface{}) *Store_DeleteTopic_Call

DeleteTopic is a helper method to define mock.On call

  • ctx context.Context
  • topic *models.Topic

func (*Store_Expecter) FetchRecord

func (_e *Store_Expecter) FetchRecord(ctx interface{}, consumer interface{}) *Store_FetchRecord_Call

FetchRecord is a helper method to define mock.On call

  • ctx context.Context
  • consumer *models.Consumer

func (*Store_Expecter) GetConsumerLag

func (_e *Store_Expecter) GetConsumerLag(ctx interface{}, consumer interface{}) *Store_GetConsumerLag_Call

GetConsumerLag is a helper method to define mock.On call

  • ctx context.Context
  • consumer *models.Consumer

func (*Store_Expecter) GetConsumerPosition

func (_e *Store_Expecter) GetConsumerPosition(ctx interface{}, consumer interface{}) *Store_GetConsumerPosition_Call

GetConsumerPosition is a helper method to define mock.On call

  • ctx context.Context
  • consumer *models.Consumer

func (*Store_Expecter) GetRecords

func (_e *Store_Expecter) GetRecords(ctx interface{}, topic interface{}, start interface{}, limit interface{}) *Store_GetRecords_Call

GetRecords is a helper method to define mock.On call

  • ctx context.Context
  • topic string
  • start string
  • limit int

func (*Store_Expecter) Impl

func (_e *Store_Expecter) Impl() *Store_Impl_Call

Impl is a helper method to define mock.On call

func (*Store_Expecter) ListTopics

func (_e *Store_Expecter) ListTopics(ctx interface{}) *Store_ListTopics_Call

ListTopics is a helper method to define mock.On call

  • ctx context.Context

func (*Store_Expecter) LoadMeta

func (_e *Store_Expecter) LoadMeta(ctx interface{}, topic interface{}) *Store_LoadMeta_Call

LoadMeta is a helper method to define mock.On call

  • ctx context.Context
  • topic string

func (*Store_Expecter) PruneOldRecords

func (_e *Store_Expecter) PruneOldRecords(ctx interface{}) *Store_PruneOldRecords_Call

PruneOldRecords is a helper method to define mock.On call

  • ctx context.Context

func (*Store_Expecter) RegisterConsumer

func (_e *Store_Expecter) RegisterConsumer(ctx interface{}, consumer interface{}) *Store_RegisterConsumer_Call

RegisterConsumer is a helper method to define mock.On call

  • ctx context.Context
  • consumer *models.Consumer

func (*Store_Expecter) SnapshotItems

func (_e *Store_Expecter) SnapshotItems() *Store_SnapshotItems_Call

SnapshotItems is a helper method to define mock.On call

func (*Store_Expecter) Stats

func (_e *Store_Expecter) Stats() *Store_Stats_Call

Stats is a helper method to define mock.On call

type Store_FetchRecord_Call

type Store_FetchRecord_Call struct {
	*mock.Call
}

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

func (*Store_FetchRecord_Call) Return

func (*Store_FetchRecord_Call) Run

func (_c *Store_FetchRecord_Call) Run(run func(ctx context.Context, consumer *models.Consumer)) *Store_FetchRecord_Call

func (*Store_FetchRecord_Call) RunAndReturn

type Store_GetConsumerLag_Call

type Store_GetConsumerLag_Call struct {
	*mock.Call
}

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

func (*Store_GetConsumerLag_Call) Return

func (*Store_GetConsumerLag_Call) Run

func (*Store_GetConsumerLag_Call) RunAndReturn

type Store_GetConsumerPosition_Call

type Store_GetConsumerPosition_Call struct {
	*mock.Call
}

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

func (*Store_GetConsumerPosition_Call) Return

func (*Store_GetConsumerPosition_Call) Run

func (*Store_GetConsumerPosition_Call) RunAndReturn

type Store_GetRecords_Call

type Store_GetRecords_Call struct {
	*mock.Call
}

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

func (*Store_GetRecords_Call) Return

func (*Store_GetRecords_Call) Run

func (_c *Store_GetRecords_Call) Run(run func(ctx context.Context, topic string, start string, limit int)) *Store_GetRecords_Call

func (*Store_GetRecords_Call) RunAndReturn

type Store_Impl_Call

type Store_Impl_Call struct {
	*mock.Call
}

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

func (*Store_Impl_Call) Return

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

func (*Store_Impl_Call) Run

func (_c *Store_Impl_Call) Run(run func()) *Store_Impl_Call

func (*Store_Impl_Call) RunAndReturn

func (_c *Store_Impl_Call) RunAndReturn(run func() interface{}) *Store_Impl_Call

type Store_ListTopics_Call

type Store_ListTopics_Call struct {
	*mock.Call
}

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

func (*Store_ListTopics_Call) Return

func (_c *Store_ListTopics_Call) Return(_a0 []string, _a1 error) *Store_ListTopics_Call

func (*Store_ListTopics_Call) Run

func (*Store_ListTopics_Call) RunAndReturn

func (_c *Store_ListTopics_Call) RunAndReturn(run func(context.Context) ([]string, error)) *Store_ListTopics_Call

type Store_LoadMeta_Call

type Store_LoadMeta_Call struct {
	*mock.Call
}

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

func (*Store_LoadMeta_Call) Return

func (_c *Store_LoadMeta_Call) Return(_a0 *models.Topic, _a1 error) *Store_LoadMeta_Call

func (*Store_LoadMeta_Call) Run

func (_c *Store_LoadMeta_Call) Run(run func(ctx context.Context, topic string)) *Store_LoadMeta_Call

func (*Store_LoadMeta_Call) RunAndReturn

func (_c *Store_LoadMeta_Call) RunAndReturn(run func(context.Context, string) (*models.Topic, error)) *Store_LoadMeta_Call

type Store_PruneOldRecords_Call

type Store_PruneOldRecords_Call struct {
	*mock.Call
}

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

func (*Store_PruneOldRecords_Call) Return

func (*Store_PruneOldRecords_Call) Run

func (*Store_PruneOldRecords_Call) RunAndReturn

type Store_RegisterConsumer_Call

type Store_RegisterConsumer_Call struct {
	*mock.Call
}

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

func (*Store_RegisterConsumer_Call) Return

func (*Store_RegisterConsumer_Call) Run

func (*Store_RegisterConsumer_Call) RunAndReturn

type Store_SnapshotItems_Call

type Store_SnapshotItems_Call struct {
	*mock.Call
}

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

func (*Store_SnapshotItems_Call) Return

func (*Store_SnapshotItems_Call) Run

func (*Store_SnapshotItems_Call) RunAndReturn

func (_c *Store_SnapshotItems_Call) RunAndReturn(run func() <-chan store.DataItem) *Store_SnapshotItems_Call

type Store_Stats_Call

type Store_Stats_Call struct {
	*mock.Call
}

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

func (*Store_Stats_Call) Return

func (_c *Store_Stats_Call) Return(_a0 map[string]*models.Topic) *Store_Stats_Call

func (*Store_Stats_Call) Run

func (_c *Store_Stats_Call) Run(run func()) *Store_Stats_Call

func (*Store_Stats_Call) RunAndReturn

func (_c *Store_Stats_Call) RunAndReturn(run func() map[string]*models.Topic) *Store_Stats_Call

Jump to

Keyboard shortcuts

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