mocks

package
v2.0.2 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2026 License: Apache-2.0, Apache-2.0 Imports: 2 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Filter

type Filter struct {
	mock.Mock
}

Filter is an autogenerated mock type for the Filter type

func NewFilter

func NewFilter(t interface {
	mock.TestingT
	Cleanup(func())
}) *Filter

NewFilter creates a new instance of Filter. 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 (*Filter) Add

func (_m *Filter) Add(ctx context.Context, id []byte) bool

Add provides a mock function with given fields: ctx, id

func (*Filter) Contains

func (_m *Filter) Contains(ctx context.Context, id []byte) bool

Contains provides a mock function with given fields: ctx, id

func (*Filter) EXPECT

func (_m *Filter) EXPECT() *Filter_Expecter

type Filter_Add_Call

type Filter_Add_Call struct {
	*mock.Call
}

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

func (*Filter_Add_Call) Return

func (_c *Filter_Add_Call) Return(evicted bool) *Filter_Add_Call

func (*Filter_Add_Call) Run

func (_c *Filter_Add_Call) Run(run func(ctx context.Context, id []byte)) *Filter_Add_Call

func (*Filter_Add_Call) RunAndReturn

func (_c *Filter_Add_Call) RunAndReturn(run func(context.Context, []byte) bool) *Filter_Add_Call

type Filter_Contains_Call

type Filter_Contains_Call struct {
	*mock.Call
}

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

func (*Filter_Contains_Call) Return

func (*Filter_Contains_Call) Run

func (_c *Filter_Contains_Call) Run(run func(ctx context.Context, id []byte)) *Filter_Contains_Call

func (*Filter_Contains_Call) RunAndReturn

func (_c *Filter_Contains_Call) RunAndReturn(run func(context.Context, []byte) bool) *Filter_Contains_Call

type Filter_Expecter

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

func (*Filter_Expecter) Add

func (_e *Filter_Expecter) Add(ctx interface{}, id interface{}) *Filter_Add_Call

Add is a helper method to define mock.On call

  • ctx context.Context
  • id []byte

func (*Filter_Expecter) Contains

func (_e *Filter_Expecter) Contains(ctx interface{}, id interface{}) *Filter_Contains_Call

Contains is a helper method to define mock.On call

  • ctx context.Context
  • id []byte

Jump to

Keyboard shortcuts

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