mocks

package
v0.0.0-...-be384fd Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

type Store[K comparable, V interface{}] struct {
	mock.Mock
}

Store is an autogenerated mock type for the Store type

func NewStore

func NewStore[K comparable, V interface{}](t interface {
	mock.TestingT
	Cleanup(func())
}) *Store[K, V]

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. The first argument is typically a *testing.T value.

func (*Store[K, V]) All

func (_m *Store[K, V]) All() []V

All provides a mock function with given fields:

func (*Store[K, V]) Delete

func (_m *Store[K, V]) Delete(key K)

Delete provides a mock function with given fields: key

func (*Store[K, V]) Get

func (_m *Store[K, V]) Get(key K) (V, bool)

Get provides a mock function with given fields: key

func (*Store[K, V]) GetAndDelete

func (_m *Store[K, V]) GetAndDelete(key K) (V, bool)

GetAndDelete provides a mock function with given fields: key

func (*Store[K, V]) IsZero

func (_m *Store[K, V]) IsZero() bool

IsZero provides a mock function with given fields:

func (*Store[K, V]) Len

func (_m *Store[K, V]) Len() int

Len provides a mock function with given fields:

func (*Store[K, V]) Put

func (_m *Store[K, V]) Put(key K, data V)

Put provides a mock function with given fields: key, data

func (*Store[K, V]) Query

func (_m *Store[K, V]) Query(spec store.QueryFunc[K, V], limit int) []V

Query provides a mock function with given fields: spec, limit

func (*Store[K, V]) Update

func (_m *Store[K, V]) Update(key K, updates ...store.UpdateFunc[K, V])

Update provides a mock function with given fields: key, updates

Jump to

Keyboard shortcuts

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