Documentation
¶
Index ¶
- type CacheMock
- func (_mock *CacheMock) Decrement(ctx context.Context, key string, by int64) (int64, error)
- func (_mock *CacheMock) Delete(ctx context.Context, key string) error
- func (_m *CacheMock) EXPECT() *CacheMock_Expecter
- func (_mock *CacheMock) Forever(ctx context.Context, key string, value any) error
- func (_mock *CacheMock) Get(ctx context.Context, key string) (any, error)
- func (_mock *CacheMock) Has(ctx context.Context, key string) (bool, error)
- func (_mock *CacheMock) Increment(ctx context.Context, key string, by int64) (int64, error)
- func (_mock *CacheMock) Pull(ctx context.Context, key string) (any, error)
- func (_mock *CacheMock) Put(ctx context.Context, key string, value any, ttl time.Duration) error
- func (_mock *CacheMock) Remember(ctx context.Context, key string, ttl time.Duration, ...) (any, error)
- func (_mock *CacheMock) RememberForever(ctx context.Context, key string, compute func() (any, error)) (any, error)
- type CacheMock_Decrement_Call
- func (_c *CacheMock_Decrement_Call) Return(n int64, err error) *CacheMock_Decrement_Call
- func (_c *CacheMock_Decrement_Call) Run(run func(ctx context.Context, key string, by int64)) *CacheMock_Decrement_Call
- func (_c *CacheMock_Decrement_Call) RunAndReturn(run func(ctx context.Context, key string, by int64) (int64, error)) *CacheMock_Decrement_Call
- type CacheMock_Delete_Call
- type CacheMock_Expecter
- func (_e *CacheMock_Expecter) Decrement(ctx interface{}, key interface{}, by interface{}) *CacheMock_Decrement_Call
- func (_e *CacheMock_Expecter) Delete(ctx interface{}, key interface{}) *CacheMock_Delete_Call
- func (_e *CacheMock_Expecter) Forever(ctx interface{}, key interface{}, value interface{}) *CacheMock_Forever_Call
- func (_e *CacheMock_Expecter) Get(ctx interface{}, key interface{}) *CacheMock_Get_Call
- func (_e *CacheMock_Expecter) Has(ctx interface{}, key interface{}) *CacheMock_Has_Call
- func (_e *CacheMock_Expecter) Increment(ctx interface{}, key interface{}, by interface{}) *CacheMock_Increment_Call
- func (_e *CacheMock_Expecter) Pull(ctx interface{}, key interface{}) *CacheMock_Pull_Call
- func (_e *CacheMock_Expecter) Put(ctx interface{}, key interface{}, value interface{}, ttl interface{}) *CacheMock_Put_Call
- func (_e *CacheMock_Expecter) Remember(ctx interface{}, key interface{}, ttl interface{}, compute interface{}) *CacheMock_Remember_Call
- func (_e *CacheMock_Expecter) RememberForever(ctx interface{}, key interface{}, compute interface{}) *CacheMock_RememberForever_Call
- type CacheMock_Forever_Call
- func (_c *CacheMock_Forever_Call) Return(err error) *CacheMock_Forever_Call
- func (_c *CacheMock_Forever_Call) Run(run func(ctx context.Context, key string, value any)) *CacheMock_Forever_Call
- func (_c *CacheMock_Forever_Call) RunAndReturn(run func(ctx context.Context, key string, value any) error) *CacheMock_Forever_Call
- type CacheMock_Get_Call
- type CacheMock_Has_Call
- type CacheMock_Increment_Call
- func (_c *CacheMock_Increment_Call) Return(n int64, err error) *CacheMock_Increment_Call
- func (_c *CacheMock_Increment_Call) Run(run func(ctx context.Context, key string, by int64)) *CacheMock_Increment_Call
- func (_c *CacheMock_Increment_Call) RunAndReturn(run func(ctx context.Context, key string, by int64) (int64, error)) *CacheMock_Increment_Call
- type CacheMock_Pull_Call
- type CacheMock_Put_Call
- func (_c *CacheMock_Put_Call) Return(err error) *CacheMock_Put_Call
- func (_c *CacheMock_Put_Call) Run(run func(ctx context.Context, key string, value any, ttl time.Duration)) *CacheMock_Put_Call
- func (_c *CacheMock_Put_Call) RunAndReturn(run func(ctx context.Context, key string, value any, ttl time.Duration) error) *CacheMock_Put_Call
- type CacheMock_RememberForever_Call
- func (_c *CacheMock_RememberForever_Call) Return(v any, err error) *CacheMock_RememberForever_Call
- func (_c *CacheMock_RememberForever_Call) Run(run func(ctx context.Context, key string, compute func() (any, error))) *CacheMock_RememberForever_Call
- func (_c *CacheMock_RememberForever_Call) RunAndReturn(...) *CacheMock_RememberForever_Call
- type CacheMock_Remember_Call
- func (_c *CacheMock_Remember_Call) Return(v any, err error) *CacheMock_Remember_Call
- func (_c *CacheMock_Remember_Call) Run(run func(ctx context.Context, key string, ttl time.Duration, ...)) *CacheMock_Remember_Call
- func (_c *CacheMock_Remember_Call) RunAndReturn(run func(ctx context.Context, key string, ttl time.Duration, ...) (any, error)) *CacheMock_Remember_Call
- type DatabaseMock
- func (_mock *DatabaseMock) Close() error
- func (_m *DatabaseMock) EXPECT() *DatabaseMock_Expecter
- func (_mock *DatabaseMock) Exec(ctx context.Context, query string, args ...any) (int64, error)
- func (_mock *DatabaseMock) ExecNamed(ctx context.Context, query string, arg any) (int64, error)
- func (_mock *DatabaseMock) Find(ctx context.Context, query string, dest any, args ...any) error
- func (_mock *DatabaseMock) FindNamed(ctx context.Context, query string, dest any, arg any) error
- func (_mock *DatabaseMock) Ping(ctx context.Context) error
- func (_mock *DatabaseMock) Select(ctx context.Context, query string, dest any, args ...any) error
- func (_mock *DatabaseMock) SelectNamed(ctx context.Context, query string, dest any, arg any) error
- func (_mock *DatabaseMock) WithTransaction(ctx context.Context, fn func(tx contract.Database) error) error
- type DatabaseMock_Close_Call
- type DatabaseMock_ExecNamed_Call
- func (_c *DatabaseMock_ExecNamed_Call) Return(n int64, err error) *DatabaseMock_ExecNamed_Call
- func (_c *DatabaseMock_ExecNamed_Call) Run(run func(ctx context.Context, query string, arg any)) *DatabaseMock_ExecNamed_Call
- func (_c *DatabaseMock_ExecNamed_Call) RunAndReturn(run func(ctx context.Context, query string, arg any) (int64, error)) *DatabaseMock_ExecNamed_Call
- type DatabaseMock_Exec_Call
- func (_c *DatabaseMock_Exec_Call) Return(n int64, err error) *DatabaseMock_Exec_Call
- func (_c *DatabaseMock_Exec_Call) Run(run func(ctx context.Context, query string, args ...any)) *DatabaseMock_Exec_Call
- func (_c *DatabaseMock_Exec_Call) RunAndReturn(run func(ctx context.Context, query string, args ...any) (int64, error)) *DatabaseMock_Exec_Call
- type DatabaseMock_Expecter
- func (_e *DatabaseMock_Expecter) Close() *DatabaseMock_Close_Call
- func (_e *DatabaseMock_Expecter) Exec(ctx interface{}, query interface{}, args ...interface{}) *DatabaseMock_Exec_Call
- func (_e *DatabaseMock_Expecter) ExecNamed(ctx interface{}, query interface{}, arg interface{}) *DatabaseMock_ExecNamed_Call
- func (_e *DatabaseMock_Expecter) Find(ctx interface{}, query interface{}, dest interface{}, args ...interface{}) *DatabaseMock_Find_Call
- func (_e *DatabaseMock_Expecter) FindNamed(ctx interface{}, query interface{}, dest interface{}, arg interface{}) *DatabaseMock_FindNamed_Call
- func (_e *DatabaseMock_Expecter) Ping(ctx interface{}) *DatabaseMock_Ping_Call
- func (_e *DatabaseMock_Expecter) Select(ctx interface{}, query interface{}, dest interface{}, args ...interface{}) *DatabaseMock_Select_Call
- func (_e *DatabaseMock_Expecter) SelectNamed(ctx interface{}, query interface{}, dest interface{}, arg interface{}) *DatabaseMock_SelectNamed_Call
- func (_e *DatabaseMock_Expecter) WithTransaction(ctx interface{}, fn interface{}) *DatabaseMock_WithTransaction_Call
- type DatabaseMock_FindNamed_Call
- func (_c *DatabaseMock_FindNamed_Call) Return(err error) *DatabaseMock_FindNamed_Call
- func (_c *DatabaseMock_FindNamed_Call) Run(run func(ctx context.Context, query string, dest any, arg any)) *DatabaseMock_FindNamed_Call
- func (_c *DatabaseMock_FindNamed_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, arg any) error) *DatabaseMock_FindNamed_Call
- type DatabaseMock_Find_Call
- func (_c *DatabaseMock_Find_Call) Return(err error) *DatabaseMock_Find_Call
- func (_c *DatabaseMock_Find_Call) Run(run func(ctx context.Context, query string, dest any, args ...any)) *DatabaseMock_Find_Call
- func (_c *DatabaseMock_Find_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, args ...any) error) *DatabaseMock_Find_Call
- type DatabaseMock_Ping_Call
- type DatabaseMock_SelectNamed_Call
- func (_c *DatabaseMock_SelectNamed_Call) Return(err error) *DatabaseMock_SelectNamed_Call
- func (_c *DatabaseMock_SelectNamed_Call) Run(run func(ctx context.Context, query string, dest any, arg any)) *DatabaseMock_SelectNamed_Call
- func (_c *DatabaseMock_SelectNamed_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, arg any) error) *DatabaseMock_SelectNamed_Call
- type DatabaseMock_Select_Call
- func (_c *DatabaseMock_Select_Call) Return(err error) *DatabaseMock_Select_Call
- func (_c *DatabaseMock_Select_Call) Run(run func(ctx context.Context, query string, dest any, args ...any)) *DatabaseMock_Select_Call
- func (_c *DatabaseMock_Select_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, args ...any) error) *DatabaseMock_Select_Call
- type DatabaseMock_WithTransaction_Call
- func (_c *DatabaseMock_WithTransaction_Call) Return(err error) *DatabaseMock_WithTransaction_Call
- func (_c *DatabaseMock_WithTransaction_Call) Run(run func(ctx context.Context, fn func(tx contract.Database) error)) *DatabaseMock_WithTransaction_Call
- func (_c *DatabaseMock_WithTransaction_Call) RunAndReturn(run func(ctx context.Context, fn func(tx contract.Database) error) error) *DatabaseMock_WithTransaction_Call
- type EncrypterMock
- type EncrypterMock_Decrypt_Call
- func (_c *EncrypterMock_Decrypt_Call) Return(bytes []byte, err error) *EncrypterMock_Decrypt_Call
- func (_c *EncrypterMock_Decrypt_Call) Run(run func(value []byte)) *EncrypterMock_Decrypt_Call
- func (_c *EncrypterMock_Decrypt_Call) RunAndReturn(run func(value []byte) ([]byte, error)) *EncrypterMock_Decrypt_Call
- type EncrypterMock_Encrypt_Call
- func (_c *EncrypterMock_Encrypt_Call) Return(bytes []byte, err error) *EncrypterMock_Encrypt_Call
- func (_c *EncrypterMock_Encrypt_Call) Run(run func(value []byte)) *EncrypterMock_Encrypt_Call
- func (_c *EncrypterMock_Encrypt_Call) RunAndReturn(run func(value []byte) ([]byte, error)) *EncrypterMock_Encrypt_Call
- type EncrypterMock_Expecter
- type EventsMock
- func (_mock *EventsMock) Close() error
- func (_m *EventsMock) EXPECT() *EventsMock_Expecter
- func (_mock *EventsMock) Publish(ctx context.Context, event string, payload any) error
- func (_mock *EventsMock) Subscribe(ctx context.Context, event string, handler contract.EventHandler) (contract.EventUnsubscribeFunc, error)
- type EventsMock_Close_Call
- type EventsMock_Expecter
- func (_e *EventsMock_Expecter) Close() *EventsMock_Close_Call
- func (_e *EventsMock_Expecter) Publish(ctx interface{}, event interface{}, payload interface{}) *EventsMock_Publish_Call
- func (_e *EventsMock_Expecter) Subscribe(ctx interface{}, event interface{}, handler interface{}) *EventsMock_Subscribe_Call
- type EventsMock_Publish_Call
- func (_c *EventsMock_Publish_Call) Return(err error) *EventsMock_Publish_Call
- func (_c *EventsMock_Publish_Call) Run(run func(ctx context.Context, event string, payload any)) *EventsMock_Publish_Call
- func (_c *EventsMock_Publish_Call) RunAndReturn(run func(ctx context.Context, event string, payload any) error) *EventsMock_Publish_Call
- type EventsMock_Subscribe_Call
- func (_c *EventsMock_Subscribe_Call) Return(v contract.EventUnsubscribeFunc, err error) *EventsMock_Subscribe_Call
- func (_c *EventsMock_Subscribe_Call) Run(run func(ctx context.Context, event string, handler contract.EventHandler)) *EventsMock_Subscribe_Call
- func (_c *EventsMock_Subscribe_Call) RunAndReturn(...) *EventsMock_Subscribe_Call
- type HasherMock
- type HasherMock_Check_Call
- type HasherMock_Expecter
- type HasherMock_Hash_Call
- type SessionDriverMock
- func (_mock *SessionDriverMock) Delete(ctx context.Context, id string) error
- func (_m *SessionDriverMock) EXPECT() *SessionDriverMock_Expecter
- func (_mock *SessionDriverMock) Get(ctx context.Context, id string) (contract.Session, error)
- func (_mock *SessionDriverMock) Save(ctx context.Context, session contract.Session, ttl time.Duration) error
- type SessionDriverMock_Delete_Call
- func (_c *SessionDriverMock_Delete_Call) Return(err error) *SessionDriverMock_Delete_Call
- func (_c *SessionDriverMock_Delete_Call) Run(run func(ctx context.Context, id string)) *SessionDriverMock_Delete_Call
- func (_c *SessionDriverMock_Delete_Call) RunAndReturn(run func(ctx context.Context, id string) error) *SessionDriverMock_Delete_Call
- type SessionDriverMock_Expecter
- func (_e *SessionDriverMock_Expecter) Delete(ctx interface{}, id interface{}) *SessionDriverMock_Delete_Call
- func (_e *SessionDriverMock_Expecter) Get(ctx interface{}, id interface{}) *SessionDriverMock_Get_Call
- func (_e *SessionDriverMock_Expecter) Save(ctx interface{}, session interface{}, ttl interface{}) *SessionDriverMock_Save_Call
- type SessionDriverMock_Get_Call
- func (_c *SessionDriverMock_Get_Call) Return(session contract.Session, err error) *SessionDriverMock_Get_Call
- func (_c *SessionDriverMock_Get_Call) Run(run func(ctx context.Context, id string)) *SessionDriverMock_Get_Call
- func (_c *SessionDriverMock_Get_Call) RunAndReturn(run func(ctx context.Context, id string) (contract.Session, error)) *SessionDriverMock_Get_Call
- type SessionDriverMock_Save_Call
- func (_c *SessionDriverMock_Save_Call) Return(err error) *SessionDriverMock_Save_Call
- func (_c *SessionDriverMock_Save_Call) Run(run func(ctx context.Context, session contract.Session, ttl time.Duration)) *SessionDriverMock_Save_Call
- func (_c *SessionDriverMock_Save_Call) RunAndReturn(...) *SessionDriverMock_Save_Call
- type SessionMock
- func (_mock *SessionMock) Clear()
- func (_mock *SessionMock) Delete(key string)
- func (_m *SessionMock) EXPECT() *SessionMock_Expecter
- func (_mock *SessionMock) ExpiresAt() time.Time
- func (_mock *SessionMock) ExpiresSoon(delta time.Duration) bool
- func (_mock *SessionMock) Extend(expiresAt time.Time)
- func (_mock *SessionMock) Get(key string) (any, bool)
- func (_mock *SessionMock) HasChanged() bool
- func (_mock *SessionMock) HasExpired() bool
- func (_mock *SessionMock) HasRegenerated() bool
- func (_mock *SessionMock) MarkAsUnchanged()
- func (_mock *SessionMock) OriginalSessionID() string
- func (_mock *SessionMock) Put(key string, value any)
- func (_mock *SessionMock) Regenerate() error
- func (_mock *SessionMock) SessionID() string
- type SessionMock_Clear_Call
- type SessionMock_Delete_Call
- type SessionMock_Expecter
- func (_e *SessionMock_Expecter) Clear() *SessionMock_Clear_Call
- func (_e *SessionMock_Expecter) Delete(key interface{}) *SessionMock_Delete_Call
- func (_e *SessionMock_Expecter) ExpiresAt() *SessionMock_ExpiresAt_Call
- func (_e *SessionMock_Expecter) ExpiresSoon(delta interface{}) *SessionMock_ExpiresSoon_Call
- func (_e *SessionMock_Expecter) Extend(expiresAt interface{}) *SessionMock_Extend_Call
- func (_e *SessionMock_Expecter) Get(key interface{}) *SessionMock_Get_Call
- func (_e *SessionMock_Expecter) HasChanged() *SessionMock_HasChanged_Call
- func (_e *SessionMock_Expecter) HasExpired() *SessionMock_HasExpired_Call
- func (_e *SessionMock_Expecter) HasRegenerated() *SessionMock_HasRegenerated_Call
- func (_e *SessionMock_Expecter) MarkAsUnchanged() *SessionMock_MarkAsUnchanged_Call
- func (_e *SessionMock_Expecter) OriginalSessionID() *SessionMock_OriginalSessionID_Call
- func (_e *SessionMock_Expecter) Put(key interface{}, value interface{}) *SessionMock_Put_Call
- func (_e *SessionMock_Expecter) Regenerate() *SessionMock_Regenerate_Call
- func (_e *SessionMock_Expecter) SessionID() *SessionMock_SessionID_Call
- type SessionMock_ExpiresAt_Call
- type SessionMock_ExpiresSoon_Call
- func (_c *SessionMock_ExpiresSoon_Call) Return(b bool) *SessionMock_ExpiresSoon_Call
- func (_c *SessionMock_ExpiresSoon_Call) Run(run func(delta time.Duration)) *SessionMock_ExpiresSoon_Call
- func (_c *SessionMock_ExpiresSoon_Call) RunAndReturn(run func(delta time.Duration) bool) *SessionMock_ExpiresSoon_Call
- type SessionMock_Extend_Call
- type SessionMock_Get_Call
- type SessionMock_HasChanged_Call
- type SessionMock_HasExpired_Call
- type SessionMock_HasRegenerated_Call
- type SessionMock_MarkAsUnchanged_Call
- type SessionMock_OriginalSessionID_Call
- func (_c *SessionMock_OriginalSessionID_Call) Return(s string) *SessionMock_OriginalSessionID_Call
- func (_c *SessionMock_OriginalSessionID_Call) Run(run func()) *SessionMock_OriginalSessionID_Call
- func (_c *SessionMock_OriginalSessionID_Call) RunAndReturn(run func() string) *SessionMock_OriginalSessionID_Call
- type SessionMock_Put_Call
- type SessionMock_Regenerate_Call
- type SessionMock_SessionID_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CacheMock ¶
CacheMock is an autogenerated mock type for the Cache type
func NewCacheMock ¶
NewCacheMock creates a new instance of CacheMock. 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 (*CacheMock) EXPECT ¶
func (_m *CacheMock) EXPECT() *CacheMock_Expecter
type CacheMock_Decrement_Call ¶
CacheMock_Decrement_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Decrement'
func (*CacheMock_Decrement_Call) Return ¶
func (_c *CacheMock_Decrement_Call) Return(n int64, err error) *CacheMock_Decrement_Call
func (*CacheMock_Decrement_Call) Run ¶
func (_c *CacheMock_Decrement_Call) Run(run func(ctx context.Context, key string, by int64)) *CacheMock_Decrement_Call
func (*CacheMock_Decrement_Call) RunAndReturn ¶
func (_c *CacheMock_Decrement_Call) RunAndReturn(run func(ctx context.Context, key string, by int64) (int64, error)) *CacheMock_Decrement_Call
type CacheMock_Delete_Call ¶
CacheMock_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*CacheMock_Delete_Call) Return ¶
func (_c *CacheMock_Delete_Call) Return(err error) *CacheMock_Delete_Call
func (*CacheMock_Delete_Call) Run ¶
func (_c *CacheMock_Delete_Call) Run(run func(ctx context.Context, key string)) *CacheMock_Delete_Call
func (*CacheMock_Delete_Call) RunAndReturn ¶
func (_c *CacheMock_Delete_Call) RunAndReturn(run func(ctx context.Context, key string) error) *CacheMock_Delete_Call
type CacheMock_Expecter ¶
type CacheMock_Expecter struct {
// contains filtered or unexported fields
}
func (*CacheMock_Expecter) Decrement ¶
func (_e *CacheMock_Expecter) Decrement(ctx interface{}, key interface{}, by interface{}) *CacheMock_Decrement_Call
Decrement is a helper method to define mock.On call
- ctx context.Context
- key string
- by int64
func (*CacheMock_Expecter) Delete ¶
func (_e *CacheMock_Expecter) Delete(ctx interface{}, key interface{}) *CacheMock_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- key string
func (*CacheMock_Expecter) Forever ¶
func (_e *CacheMock_Expecter) Forever(ctx interface{}, key interface{}, value interface{}) *CacheMock_Forever_Call
Forever is a helper method to define mock.On call
- ctx context.Context
- key string
- value any
func (*CacheMock_Expecter) Get ¶
func (_e *CacheMock_Expecter) Get(ctx interface{}, key interface{}) *CacheMock_Get_Call
Get is a helper method to define mock.On call
- ctx context.Context
- key string
func (*CacheMock_Expecter) Has ¶
func (_e *CacheMock_Expecter) Has(ctx interface{}, key interface{}) *CacheMock_Has_Call
Has is a helper method to define mock.On call
- ctx context.Context
- key string
func (*CacheMock_Expecter) Increment ¶
func (_e *CacheMock_Expecter) Increment(ctx interface{}, key interface{}, by interface{}) *CacheMock_Increment_Call
Increment is a helper method to define mock.On call
- ctx context.Context
- key string
- by int64
func (*CacheMock_Expecter) Pull ¶
func (_e *CacheMock_Expecter) Pull(ctx interface{}, key interface{}) *CacheMock_Pull_Call
Pull is a helper method to define mock.On call
- ctx context.Context
- key string
func (*CacheMock_Expecter) Put ¶
func (_e *CacheMock_Expecter) Put(ctx interface{}, key interface{}, value interface{}, ttl interface{}) *CacheMock_Put_Call
Put is a helper method to define mock.On call
- ctx context.Context
- key string
- value any
- ttl time.Duration
func (*CacheMock_Expecter) Remember ¶
func (_e *CacheMock_Expecter) Remember(ctx interface{}, key interface{}, ttl interface{}, compute interface{}) *CacheMock_Remember_Call
Remember is a helper method to define mock.On call
- ctx context.Context
- key string
- ttl time.Duration
- compute func() (any, error)
func (*CacheMock_Expecter) RememberForever ¶
func (_e *CacheMock_Expecter) RememberForever(ctx interface{}, key interface{}, compute interface{}) *CacheMock_RememberForever_Call
RememberForever is a helper method to define mock.On call
- ctx context.Context
- key string
- compute func() (any, error)
type CacheMock_Forever_Call ¶
CacheMock_Forever_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Forever'
func (*CacheMock_Forever_Call) Return ¶
func (_c *CacheMock_Forever_Call) Return(err error) *CacheMock_Forever_Call
func (*CacheMock_Forever_Call) Run ¶
func (_c *CacheMock_Forever_Call) Run(run func(ctx context.Context, key string, value any)) *CacheMock_Forever_Call
func (*CacheMock_Forever_Call) RunAndReturn ¶
func (_c *CacheMock_Forever_Call) RunAndReturn(run func(ctx context.Context, key string, value any) error) *CacheMock_Forever_Call
type CacheMock_Get_Call ¶
CacheMock_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*CacheMock_Get_Call) Return ¶
func (_c *CacheMock_Get_Call) Return(v any, err error) *CacheMock_Get_Call
func (*CacheMock_Get_Call) Run ¶
func (_c *CacheMock_Get_Call) Run(run func(ctx context.Context, key string)) *CacheMock_Get_Call
func (*CacheMock_Get_Call) RunAndReturn ¶
func (_c *CacheMock_Get_Call) RunAndReturn(run func(ctx context.Context, key string) (any, error)) *CacheMock_Get_Call
type CacheMock_Has_Call ¶
CacheMock_Has_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Has'
func (*CacheMock_Has_Call) Return ¶
func (_c *CacheMock_Has_Call) Return(b bool, err error) *CacheMock_Has_Call
func (*CacheMock_Has_Call) Run ¶
func (_c *CacheMock_Has_Call) Run(run func(ctx context.Context, key string)) *CacheMock_Has_Call
func (*CacheMock_Has_Call) RunAndReturn ¶
func (_c *CacheMock_Has_Call) RunAndReturn(run func(ctx context.Context, key string) (bool, error)) *CacheMock_Has_Call
type CacheMock_Increment_Call ¶
CacheMock_Increment_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Increment'
func (*CacheMock_Increment_Call) Return ¶
func (_c *CacheMock_Increment_Call) Return(n int64, err error) *CacheMock_Increment_Call
func (*CacheMock_Increment_Call) Run ¶
func (_c *CacheMock_Increment_Call) Run(run func(ctx context.Context, key string, by int64)) *CacheMock_Increment_Call
func (*CacheMock_Increment_Call) RunAndReturn ¶
func (_c *CacheMock_Increment_Call) RunAndReturn(run func(ctx context.Context, key string, by int64) (int64, error)) *CacheMock_Increment_Call
type CacheMock_Pull_Call ¶
CacheMock_Pull_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Pull'
func (*CacheMock_Pull_Call) Return ¶
func (_c *CacheMock_Pull_Call) Return(v any, err error) *CacheMock_Pull_Call
func (*CacheMock_Pull_Call) Run ¶
func (_c *CacheMock_Pull_Call) Run(run func(ctx context.Context, key string)) *CacheMock_Pull_Call
func (*CacheMock_Pull_Call) RunAndReturn ¶
func (_c *CacheMock_Pull_Call) RunAndReturn(run func(ctx context.Context, key string) (any, error)) *CacheMock_Pull_Call
type CacheMock_Put_Call ¶
CacheMock_Put_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Put'
func (*CacheMock_Put_Call) Return ¶
func (_c *CacheMock_Put_Call) Return(err error) *CacheMock_Put_Call
func (*CacheMock_Put_Call) Run ¶
func (_c *CacheMock_Put_Call) Run(run func(ctx context.Context, key string, value any, ttl time.Duration)) *CacheMock_Put_Call
func (*CacheMock_Put_Call) RunAndReturn ¶
func (_c *CacheMock_Put_Call) RunAndReturn(run func(ctx context.Context, key string, value any, ttl time.Duration) error) *CacheMock_Put_Call
type CacheMock_RememberForever_Call ¶
CacheMock_RememberForever_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RememberForever'
func (*CacheMock_RememberForever_Call) Return ¶
func (_c *CacheMock_RememberForever_Call) Return(v any, err error) *CacheMock_RememberForever_Call
func (*CacheMock_RememberForever_Call) Run ¶
func (_c *CacheMock_RememberForever_Call) Run(run func(ctx context.Context, key string, compute func() (any, error))) *CacheMock_RememberForever_Call
func (*CacheMock_RememberForever_Call) RunAndReturn ¶
func (_c *CacheMock_RememberForever_Call) RunAndReturn(run func(ctx context.Context, key string, compute func() (any, error)) (any, error)) *CacheMock_RememberForever_Call
type CacheMock_Remember_Call ¶
CacheMock_Remember_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remember'
func (*CacheMock_Remember_Call) Return ¶
func (_c *CacheMock_Remember_Call) Return(v any, err error) *CacheMock_Remember_Call
func (*CacheMock_Remember_Call) Run ¶
func (_c *CacheMock_Remember_Call) Run(run func(ctx context.Context, key string, ttl time.Duration, compute func() (any, error))) *CacheMock_Remember_Call
func (*CacheMock_Remember_Call) RunAndReturn ¶
type DatabaseMock ¶
DatabaseMock is an autogenerated mock type for the Database type
func NewDatabaseMock ¶
func NewDatabaseMock(t interface {
mock.TestingT
Cleanup(func())
}) *DatabaseMock
NewDatabaseMock creates a new instance of DatabaseMock. 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 (*DatabaseMock) Close ¶
func (_mock *DatabaseMock) Close() error
Close provides a mock function for the type DatabaseMock
func (*DatabaseMock) EXPECT ¶
func (_m *DatabaseMock) EXPECT() *DatabaseMock_Expecter
func (*DatabaseMock) Ping ¶
func (_mock *DatabaseMock) Ping(ctx context.Context) error
Ping provides a mock function for the type DatabaseMock
func (*DatabaseMock) SelectNamed ¶
SelectNamed provides a mock function for the type DatabaseMock
func (*DatabaseMock) WithTransaction ¶
func (_mock *DatabaseMock) WithTransaction(ctx context.Context, fn func(tx contract.Database) error) error
WithTransaction provides a mock function for the type DatabaseMock
type DatabaseMock_Close_Call ¶
DatabaseMock_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
func (*DatabaseMock_Close_Call) Return ¶
func (_c *DatabaseMock_Close_Call) Return(err error) *DatabaseMock_Close_Call
func (*DatabaseMock_Close_Call) Run ¶
func (_c *DatabaseMock_Close_Call) Run(run func()) *DatabaseMock_Close_Call
func (*DatabaseMock_Close_Call) RunAndReturn ¶
func (_c *DatabaseMock_Close_Call) RunAndReturn(run func() error) *DatabaseMock_Close_Call
type DatabaseMock_ExecNamed_Call ¶
DatabaseMock_ExecNamed_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExecNamed'
func (*DatabaseMock_ExecNamed_Call) Return ¶
func (_c *DatabaseMock_ExecNamed_Call) Return(n int64, err error) *DatabaseMock_ExecNamed_Call
func (*DatabaseMock_ExecNamed_Call) Run ¶
func (_c *DatabaseMock_ExecNamed_Call) Run(run func(ctx context.Context, query string, arg any)) *DatabaseMock_ExecNamed_Call
func (*DatabaseMock_ExecNamed_Call) RunAndReturn ¶
func (_c *DatabaseMock_ExecNamed_Call) RunAndReturn(run func(ctx context.Context, query string, arg any) (int64, error)) *DatabaseMock_ExecNamed_Call
type DatabaseMock_Exec_Call ¶
DatabaseMock_Exec_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Exec'
func (*DatabaseMock_Exec_Call) Return ¶
func (_c *DatabaseMock_Exec_Call) Return(n int64, err error) *DatabaseMock_Exec_Call
func (*DatabaseMock_Exec_Call) Run ¶
func (_c *DatabaseMock_Exec_Call) Run(run func(ctx context.Context, query string, args ...any)) *DatabaseMock_Exec_Call
func (*DatabaseMock_Exec_Call) RunAndReturn ¶
func (_c *DatabaseMock_Exec_Call) RunAndReturn(run func(ctx context.Context, query string, args ...any) (int64, error)) *DatabaseMock_Exec_Call
type DatabaseMock_Expecter ¶
type DatabaseMock_Expecter struct {
// contains filtered or unexported fields
}
func (*DatabaseMock_Expecter) Close ¶
func (_e *DatabaseMock_Expecter) Close() *DatabaseMock_Close_Call
Close is a helper method to define mock.On call
func (*DatabaseMock_Expecter) Exec ¶
func (_e *DatabaseMock_Expecter) Exec(ctx interface{}, query interface{}, args ...interface{}) *DatabaseMock_Exec_Call
Exec is a helper method to define mock.On call
- ctx context.Context
- query string
- args ...any
func (*DatabaseMock_Expecter) ExecNamed ¶
func (_e *DatabaseMock_Expecter) ExecNamed(ctx interface{}, query interface{}, arg interface{}) *DatabaseMock_ExecNamed_Call
ExecNamed is a helper method to define mock.On call
- ctx context.Context
- query string
- arg any
func (*DatabaseMock_Expecter) Find ¶
func (_e *DatabaseMock_Expecter) Find(ctx interface{}, query interface{}, dest interface{}, args ...interface{}) *DatabaseMock_Find_Call
Find is a helper method to define mock.On call
- ctx context.Context
- query string
- dest any
- args ...any
func (*DatabaseMock_Expecter) FindNamed ¶
func (_e *DatabaseMock_Expecter) FindNamed(ctx interface{}, query interface{}, dest interface{}, arg interface{}) *DatabaseMock_FindNamed_Call
FindNamed is a helper method to define mock.On call
- ctx context.Context
- query string
- dest any
- arg any
func (*DatabaseMock_Expecter) Ping ¶
func (_e *DatabaseMock_Expecter) Ping(ctx interface{}) *DatabaseMock_Ping_Call
Ping is a helper method to define mock.On call
- ctx context.Context
func (*DatabaseMock_Expecter) Select ¶
func (_e *DatabaseMock_Expecter) Select(ctx interface{}, query interface{}, dest interface{}, args ...interface{}) *DatabaseMock_Select_Call
Select is a helper method to define mock.On call
- ctx context.Context
- query string
- dest any
- args ...any
func (*DatabaseMock_Expecter) SelectNamed ¶
func (_e *DatabaseMock_Expecter) SelectNamed(ctx interface{}, query interface{}, dest interface{}, arg interface{}) *DatabaseMock_SelectNamed_Call
SelectNamed is a helper method to define mock.On call
- ctx context.Context
- query string
- dest any
- arg any
func (*DatabaseMock_Expecter) WithTransaction ¶
func (_e *DatabaseMock_Expecter) WithTransaction(ctx interface{}, fn interface{}) *DatabaseMock_WithTransaction_Call
WithTransaction is a helper method to define mock.On call
- ctx context.Context
- fn func(tx contract.Database) error
type DatabaseMock_FindNamed_Call ¶
DatabaseMock_FindNamed_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindNamed'
func (*DatabaseMock_FindNamed_Call) Return ¶
func (_c *DatabaseMock_FindNamed_Call) Return(err error) *DatabaseMock_FindNamed_Call
func (*DatabaseMock_FindNamed_Call) Run ¶
func (_c *DatabaseMock_FindNamed_Call) Run(run func(ctx context.Context, query string, dest any, arg any)) *DatabaseMock_FindNamed_Call
func (*DatabaseMock_FindNamed_Call) RunAndReturn ¶
func (_c *DatabaseMock_FindNamed_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, arg any) error) *DatabaseMock_FindNamed_Call
type DatabaseMock_Find_Call ¶
DatabaseMock_Find_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Find'
func (*DatabaseMock_Find_Call) Return ¶
func (_c *DatabaseMock_Find_Call) Return(err error) *DatabaseMock_Find_Call
func (*DatabaseMock_Find_Call) Run ¶
func (_c *DatabaseMock_Find_Call) Run(run func(ctx context.Context, query string, dest any, args ...any)) *DatabaseMock_Find_Call
func (*DatabaseMock_Find_Call) RunAndReturn ¶
func (_c *DatabaseMock_Find_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, args ...any) error) *DatabaseMock_Find_Call
type DatabaseMock_Ping_Call ¶
DatabaseMock_Ping_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Ping'
func (*DatabaseMock_Ping_Call) Return ¶
func (_c *DatabaseMock_Ping_Call) Return(err error) *DatabaseMock_Ping_Call
func (*DatabaseMock_Ping_Call) Run ¶
func (_c *DatabaseMock_Ping_Call) Run(run func(ctx context.Context)) *DatabaseMock_Ping_Call
func (*DatabaseMock_Ping_Call) RunAndReturn ¶
func (_c *DatabaseMock_Ping_Call) RunAndReturn(run func(ctx context.Context) error) *DatabaseMock_Ping_Call
type DatabaseMock_SelectNamed_Call ¶
DatabaseMock_SelectNamed_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SelectNamed'
func (*DatabaseMock_SelectNamed_Call) Return ¶
func (_c *DatabaseMock_SelectNamed_Call) Return(err error) *DatabaseMock_SelectNamed_Call
func (*DatabaseMock_SelectNamed_Call) Run ¶
func (_c *DatabaseMock_SelectNamed_Call) Run(run func(ctx context.Context, query string, dest any, arg any)) *DatabaseMock_SelectNamed_Call
func (*DatabaseMock_SelectNamed_Call) RunAndReturn ¶
func (_c *DatabaseMock_SelectNamed_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, arg any) error) *DatabaseMock_SelectNamed_Call
type DatabaseMock_Select_Call ¶
DatabaseMock_Select_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Select'
func (*DatabaseMock_Select_Call) Return ¶
func (_c *DatabaseMock_Select_Call) Return(err error) *DatabaseMock_Select_Call
func (*DatabaseMock_Select_Call) Run ¶
func (_c *DatabaseMock_Select_Call) Run(run func(ctx context.Context, query string, dest any, args ...any)) *DatabaseMock_Select_Call
func (*DatabaseMock_Select_Call) RunAndReturn ¶
func (_c *DatabaseMock_Select_Call) RunAndReturn(run func(ctx context.Context, query string, dest any, args ...any) error) *DatabaseMock_Select_Call
type DatabaseMock_WithTransaction_Call ¶
DatabaseMock_WithTransaction_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'WithTransaction'
func (*DatabaseMock_WithTransaction_Call) Return ¶
func (_c *DatabaseMock_WithTransaction_Call) Return(err error) *DatabaseMock_WithTransaction_Call
func (*DatabaseMock_WithTransaction_Call) Run ¶
func (_c *DatabaseMock_WithTransaction_Call) Run(run func(ctx context.Context, fn func(tx contract.Database) error)) *DatabaseMock_WithTransaction_Call
func (*DatabaseMock_WithTransaction_Call) RunAndReturn ¶
func (_c *DatabaseMock_WithTransaction_Call) RunAndReturn(run func(ctx context.Context, fn func(tx contract.Database) error) error) *DatabaseMock_WithTransaction_Call
type EncrypterMock ¶ added in v0.5.0
EncrypterMock is an autogenerated mock type for the Encrypter type
func NewEncrypterMock ¶ added in v0.5.0
func NewEncrypterMock(t interface {
mock.TestingT
Cleanup(func())
}) *EncrypterMock
NewEncrypterMock creates a new instance of EncrypterMock. 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 (*EncrypterMock) Decrypt ¶ added in v0.5.0
func (_mock *EncrypterMock) Decrypt(value []byte) ([]byte, error)
Decrypt provides a mock function for the type EncrypterMock
func (*EncrypterMock) EXPECT ¶ added in v0.5.0
func (_m *EncrypterMock) EXPECT() *EncrypterMock_Expecter
type EncrypterMock_Decrypt_Call ¶ added in v0.5.0
EncrypterMock_Decrypt_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Decrypt'
func (*EncrypterMock_Decrypt_Call) Return ¶ added in v0.5.0
func (_c *EncrypterMock_Decrypt_Call) Return(bytes []byte, err error) *EncrypterMock_Decrypt_Call
func (*EncrypterMock_Decrypt_Call) Run ¶ added in v0.5.0
func (_c *EncrypterMock_Decrypt_Call) Run(run func(value []byte)) *EncrypterMock_Decrypt_Call
func (*EncrypterMock_Decrypt_Call) RunAndReturn ¶ added in v0.5.0
func (_c *EncrypterMock_Decrypt_Call) RunAndReturn(run func(value []byte) ([]byte, error)) *EncrypterMock_Decrypt_Call
type EncrypterMock_Encrypt_Call ¶ added in v0.5.0
EncrypterMock_Encrypt_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Encrypt'
func (*EncrypterMock_Encrypt_Call) Return ¶ added in v0.5.0
func (_c *EncrypterMock_Encrypt_Call) Return(bytes []byte, err error) *EncrypterMock_Encrypt_Call
func (*EncrypterMock_Encrypt_Call) Run ¶ added in v0.5.0
func (_c *EncrypterMock_Encrypt_Call) Run(run func(value []byte)) *EncrypterMock_Encrypt_Call
func (*EncrypterMock_Encrypt_Call) RunAndReturn ¶ added in v0.5.0
func (_c *EncrypterMock_Encrypt_Call) RunAndReturn(run func(value []byte) ([]byte, error)) *EncrypterMock_Encrypt_Call
type EncrypterMock_Expecter ¶ added in v0.5.0
type EncrypterMock_Expecter struct {
// contains filtered or unexported fields
}
func (*EncrypterMock_Expecter) Decrypt ¶ added in v0.5.0
func (_e *EncrypterMock_Expecter) Decrypt(value interface{}) *EncrypterMock_Decrypt_Call
Decrypt is a helper method to define mock.On call
- value []byte
func (*EncrypterMock_Expecter) Encrypt ¶ added in v0.5.0
func (_e *EncrypterMock_Expecter) Encrypt(value interface{}) *EncrypterMock_Encrypt_Call
Encrypt is a helper method to define mock.On call
- value []byte
type EventsMock ¶ added in v0.8.0
EventsMock is an autogenerated mock type for the Events type
func NewEventsMock ¶ added in v0.8.0
func NewEventsMock(t interface {
mock.TestingT
Cleanup(func())
}) *EventsMock
NewEventsMock creates a new instance of EventsMock. 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 (*EventsMock) Close ¶ added in v0.8.0
func (_mock *EventsMock) Close() error
Close provides a mock function for the type EventsMock
func (*EventsMock) EXPECT ¶ added in v0.8.0
func (_m *EventsMock) EXPECT() *EventsMock_Expecter
func (*EventsMock) Publish ¶ added in v0.8.0
Publish provides a mock function for the type EventsMock
func (*EventsMock) Subscribe ¶ added in v0.8.0
func (_mock *EventsMock) Subscribe(ctx context.Context, event string, handler contract.EventHandler) (contract.EventUnsubscribeFunc, error)
Subscribe provides a mock function for the type EventsMock
type EventsMock_Close_Call ¶ added in v0.8.0
EventsMock_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
func (*EventsMock_Close_Call) Return ¶ added in v0.8.0
func (_c *EventsMock_Close_Call) Return(err error) *EventsMock_Close_Call
func (*EventsMock_Close_Call) Run ¶ added in v0.8.0
func (_c *EventsMock_Close_Call) Run(run func()) *EventsMock_Close_Call
func (*EventsMock_Close_Call) RunAndReturn ¶ added in v0.8.0
func (_c *EventsMock_Close_Call) RunAndReturn(run func() error) *EventsMock_Close_Call
type EventsMock_Expecter ¶ added in v0.8.0
type EventsMock_Expecter struct {
// contains filtered or unexported fields
}
func (*EventsMock_Expecter) Close ¶ added in v0.8.0
func (_e *EventsMock_Expecter) Close() *EventsMock_Close_Call
Close is a helper method to define mock.On call
func (*EventsMock_Expecter) Publish ¶ added in v0.8.0
func (_e *EventsMock_Expecter) Publish(ctx interface{}, event interface{}, payload interface{}) *EventsMock_Publish_Call
Publish is a helper method to define mock.On call
- ctx context.Context
- event string
- payload any
func (*EventsMock_Expecter) Subscribe ¶ added in v0.8.0
func (_e *EventsMock_Expecter) Subscribe(ctx interface{}, event interface{}, handler interface{}) *EventsMock_Subscribe_Call
Subscribe is a helper method to define mock.On call
- ctx context.Context
- event string
- handler contract.EventHandler
type EventsMock_Publish_Call ¶ added in v0.8.0
EventsMock_Publish_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Publish'
func (*EventsMock_Publish_Call) Return ¶ added in v0.8.0
func (_c *EventsMock_Publish_Call) Return(err error) *EventsMock_Publish_Call
func (*EventsMock_Publish_Call) Run ¶ added in v0.8.0
func (_c *EventsMock_Publish_Call) Run(run func(ctx context.Context, event string, payload any)) *EventsMock_Publish_Call
func (*EventsMock_Publish_Call) RunAndReturn ¶ added in v0.8.0
func (_c *EventsMock_Publish_Call) RunAndReturn(run func(ctx context.Context, event string, payload any) error) *EventsMock_Publish_Call
type EventsMock_Subscribe_Call ¶ added in v0.8.0
EventsMock_Subscribe_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Subscribe'
func (*EventsMock_Subscribe_Call) Return ¶ added in v0.8.0
func (_c *EventsMock_Subscribe_Call) Return(v contract.EventUnsubscribeFunc, err error) *EventsMock_Subscribe_Call
func (*EventsMock_Subscribe_Call) Run ¶ added in v0.8.0
func (_c *EventsMock_Subscribe_Call) Run(run func(ctx context.Context, event string, handler contract.EventHandler)) *EventsMock_Subscribe_Call
func (*EventsMock_Subscribe_Call) RunAndReturn ¶ added in v0.8.0
func (_c *EventsMock_Subscribe_Call) RunAndReturn(run func(ctx context.Context, event string, handler contract.EventHandler) (contract.EventUnsubscribeFunc, error)) *EventsMock_Subscribe_Call
type HasherMock ¶ added in v0.5.0
HasherMock is an autogenerated mock type for the Hasher type
func NewHasherMock ¶ added in v0.5.0
func NewHasherMock(t interface {
mock.TestingT
Cleanup(func())
}) *HasherMock
NewHasherMock creates a new instance of HasherMock. 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 (*HasherMock) Check ¶ added in v0.5.0
func (_mock *HasherMock) Check(value []byte, hash []byte) (bool, error)
Check provides a mock function for the type HasherMock
func (*HasherMock) EXPECT ¶ added in v0.5.0
func (_m *HasherMock) EXPECT() *HasherMock_Expecter
type HasherMock_Check_Call ¶ added in v0.5.0
HasherMock_Check_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Check'
func (*HasherMock_Check_Call) Return ¶ added in v0.5.0
func (_c *HasherMock_Check_Call) Return(b bool, err error) *HasherMock_Check_Call
func (*HasherMock_Check_Call) Run ¶ added in v0.5.0
func (_c *HasherMock_Check_Call) Run(run func(value []byte, hash []byte)) *HasherMock_Check_Call
func (*HasherMock_Check_Call) RunAndReturn ¶ added in v0.5.0
func (_c *HasherMock_Check_Call) RunAndReturn(run func(value []byte, hash []byte) (bool, error)) *HasherMock_Check_Call
type HasherMock_Expecter ¶ added in v0.5.0
type HasherMock_Expecter struct {
// contains filtered or unexported fields
}
func (*HasherMock_Expecter) Check ¶ added in v0.5.0
func (_e *HasherMock_Expecter) Check(value interface{}, hash interface{}) *HasherMock_Check_Call
Check is a helper method to define mock.On call
- value []byte
- hash []byte
func (*HasherMock_Expecter) Hash ¶ added in v0.5.0
func (_e *HasherMock_Expecter) Hash(value interface{}) *HasherMock_Hash_Call
Hash is a helper method to define mock.On call
- value []byte
type HasherMock_Hash_Call ¶ added in v0.5.0
HasherMock_Hash_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Hash'
func (*HasherMock_Hash_Call) Return ¶ added in v0.5.0
func (_c *HasherMock_Hash_Call) Return(bytes []byte, err error) *HasherMock_Hash_Call
func (*HasherMock_Hash_Call) Run ¶ added in v0.5.0
func (_c *HasherMock_Hash_Call) Run(run func(value []byte)) *HasherMock_Hash_Call
func (*HasherMock_Hash_Call) RunAndReturn ¶ added in v0.5.0
func (_c *HasherMock_Hash_Call) RunAndReturn(run func(value []byte) ([]byte, error)) *HasherMock_Hash_Call
type SessionDriverMock ¶ added in v0.5.0
SessionDriverMock is an autogenerated mock type for the SessionDriver type
func NewSessionDriverMock ¶ added in v0.5.0
func NewSessionDriverMock(t interface {
mock.TestingT
Cleanup(func())
}) *SessionDriverMock
NewSessionDriverMock creates a new instance of SessionDriverMock. 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 (*SessionDriverMock) Delete ¶ added in v0.5.0
func (_mock *SessionDriverMock) Delete(ctx context.Context, id string) error
Delete provides a mock function for the type SessionDriverMock
func (*SessionDriverMock) EXPECT ¶ added in v0.5.0
func (_m *SessionDriverMock) EXPECT() *SessionDriverMock_Expecter
type SessionDriverMock_Delete_Call ¶ added in v0.5.0
SessionDriverMock_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*SessionDriverMock_Delete_Call) Return ¶ added in v0.5.0
func (_c *SessionDriverMock_Delete_Call) Return(err error) *SessionDriverMock_Delete_Call
func (*SessionDriverMock_Delete_Call) Run ¶ added in v0.5.0
func (_c *SessionDriverMock_Delete_Call) Run(run func(ctx context.Context, id string)) *SessionDriverMock_Delete_Call
func (*SessionDriverMock_Delete_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionDriverMock_Delete_Call) RunAndReturn(run func(ctx context.Context, id string) error) *SessionDriverMock_Delete_Call
type SessionDriverMock_Expecter ¶ added in v0.5.0
type SessionDriverMock_Expecter struct {
// contains filtered or unexported fields
}
func (*SessionDriverMock_Expecter) Delete ¶ added in v0.5.0
func (_e *SessionDriverMock_Expecter) Delete(ctx interface{}, id interface{}) *SessionDriverMock_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- id string
func (*SessionDriverMock_Expecter) Get ¶ added in v0.5.0
func (_e *SessionDriverMock_Expecter) Get(ctx interface{}, id interface{}) *SessionDriverMock_Get_Call
Get is a helper method to define mock.On call
- ctx context.Context
- id string
func (*SessionDriverMock_Expecter) Save ¶ added in v0.5.0
func (_e *SessionDriverMock_Expecter) Save(ctx interface{}, session interface{}, ttl interface{}) *SessionDriverMock_Save_Call
Save is a helper method to define mock.On call
- ctx context.Context
- session contract.Session
- ttl time.Duration
type SessionDriverMock_Get_Call ¶ added in v0.5.0
SessionDriverMock_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*SessionDriverMock_Get_Call) Return ¶ added in v0.5.0
func (_c *SessionDriverMock_Get_Call) Return(session contract.Session, err error) *SessionDriverMock_Get_Call
func (*SessionDriverMock_Get_Call) Run ¶ added in v0.5.0
func (_c *SessionDriverMock_Get_Call) Run(run func(ctx context.Context, id string)) *SessionDriverMock_Get_Call
func (*SessionDriverMock_Get_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionDriverMock_Get_Call) RunAndReturn(run func(ctx context.Context, id string) (contract.Session, error)) *SessionDriverMock_Get_Call
type SessionDriverMock_Save_Call ¶ added in v0.5.0
SessionDriverMock_Save_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Save'
func (*SessionDriverMock_Save_Call) Return ¶ added in v0.5.0
func (_c *SessionDriverMock_Save_Call) Return(err error) *SessionDriverMock_Save_Call
func (*SessionDriverMock_Save_Call) Run ¶ added in v0.5.0
func (_c *SessionDriverMock_Save_Call) Run(run func(ctx context.Context, session contract.Session, ttl time.Duration)) *SessionDriverMock_Save_Call
func (*SessionDriverMock_Save_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionDriverMock_Save_Call) RunAndReturn(run func(ctx context.Context, session contract.Session, ttl time.Duration) error) *SessionDriverMock_Save_Call
type SessionMock ¶ added in v0.5.0
SessionMock is an autogenerated mock type for the Session type
func NewSessionMock ¶ added in v0.5.0
func NewSessionMock(t interface {
mock.TestingT
Cleanup(func())
}) *SessionMock
NewSessionMock creates a new instance of SessionMock. 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 (*SessionMock) Clear ¶ added in v0.5.0
func (_mock *SessionMock) Clear()
Clear provides a mock function for the type SessionMock
func (*SessionMock) Delete ¶ added in v0.5.0
func (_mock *SessionMock) Delete(key string)
Delete provides a mock function for the type SessionMock
func (*SessionMock) EXPECT ¶ added in v0.5.0
func (_m *SessionMock) EXPECT() *SessionMock_Expecter
func (*SessionMock) ExpiresAt ¶ added in v0.5.0
func (_mock *SessionMock) ExpiresAt() time.Time
ExpiresAt provides a mock function for the type SessionMock
func (*SessionMock) ExpiresSoon ¶ added in v0.5.0
func (_mock *SessionMock) ExpiresSoon(delta time.Duration) bool
ExpiresSoon provides a mock function for the type SessionMock
func (*SessionMock) Extend ¶ added in v0.5.0
func (_mock *SessionMock) Extend(expiresAt time.Time)
Extend provides a mock function for the type SessionMock
func (*SessionMock) Get ¶ added in v0.5.0
func (_mock *SessionMock) Get(key string) (any, bool)
Get provides a mock function for the type SessionMock
func (*SessionMock) HasChanged ¶ added in v0.5.0
func (_mock *SessionMock) HasChanged() bool
HasChanged provides a mock function for the type SessionMock
func (*SessionMock) HasExpired ¶ added in v0.5.0
func (_mock *SessionMock) HasExpired() bool
HasExpired provides a mock function for the type SessionMock
func (*SessionMock) HasRegenerated ¶ added in v0.5.0
func (_mock *SessionMock) HasRegenerated() bool
HasRegenerated provides a mock function for the type SessionMock
func (*SessionMock) MarkAsUnchanged ¶ added in v0.6.1
func (_mock *SessionMock) MarkAsUnchanged()
MarkAsUnchanged provides a mock function for the type SessionMock
func (*SessionMock) OriginalSessionID ¶ added in v0.5.0
func (_mock *SessionMock) OriginalSessionID() string
OriginalSessionID provides a mock function for the type SessionMock
func (*SessionMock) Put ¶ added in v0.5.0
func (_mock *SessionMock) Put(key string, value any)
Put provides a mock function for the type SessionMock
func (*SessionMock) Regenerate ¶ added in v0.5.0
func (_mock *SessionMock) Regenerate() error
Regenerate provides a mock function for the type SessionMock
func (*SessionMock) SessionID ¶ added in v0.5.0
func (_mock *SessionMock) SessionID() string
SessionID provides a mock function for the type SessionMock
type SessionMock_Clear_Call ¶ added in v0.5.0
SessionMock_Clear_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Clear'
func (*SessionMock_Clear_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Clear_Call) Return() *SessionMock_Clear_Call
func (*SessionMock_Clear_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Clear_Call) Run(run func()) *SessionMock_Clear_Call
func (*SessionMock_Clear_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Clear_Call) RunAndReturn(run func()) *SessionMock_Clear_Call
type SessionMock_Delete_Call ¶ added in v0.5.0
SessionMock_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*SessionMock_Delete_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Delete_Call) Return() *SessionMock_Delete_Call
func (*SessionMock_Delete_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Delete_Call) Run(run func(key string)) *SessionMock_Delete_Call
func (*SessionMock_Delete_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Delete_Call) RunAndReturn(run func(key string)) *SessionMock_Delete_Call
type SessionMock_Expecter ¶ added in v0.5.0
type SessionMock_Expecter struct {
// contains filtered or unexported fields
}
func (*SessionMock_Expecter) Clear ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Clear() *SessionMock_Clear_Call
Clear is a helper method to define mock.On call
func (*SessionMock_Expecter) Delete ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Delete(key interface{}) *SessionMock_Delete_Call
Delete is a helper method to define mock.On call
- key string
func (*SessionMock_Expecter) ExpiresAt ¶ added in v0.5.0
func (_e *SessionMock_Expecter) ExpiresAt() *SessionMock_ExpiresAt_Call
ExpiresAt is a helper method to define mock.On call
func (*SessionMock_Expecter) ExpiresSoon ¶ added in v0.5.0
func (_e *SessionMock_Expecter) ExpiresSoon(delta interface{}) *SessionMock_ExpiresSoon_Call
ExpiresSoon is a helper method to define mock.On call
- delta time.Duration
func (*SessionMock_Expecter) Extend ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Extend(expiresAt interface{}) *SessionMock_Extend_Call
Extend is a helper method to define mock.On call
- expiresAt time.Time
func (*SessionMock_Expecter) Get ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Get(key interface{}) *SessionMock_Get_Call
Get is a helper method to define mock.On call
- key string
func (*SessionMock_Expecter) HasChanged ¶ added in v0.5.0
func (_e *SessionMock_Expecter) HasChanged() *SessionMock_HasChanged_Call
HasChanged is a helper method to define mock.On call
func (*SessionMock_Expecter) HasExpired ¶ added in v0.5.0
func (_e *SessionMock_Expecter) HasExpired() *SessionMock_HasExpired_Call
HasExpired is a helper method to define mock.On call
func (*SessionMock_Expecter) HasRegenerated ¶ added in v0.5.0
func (_e *SessionMock_Expecter) HasRegenerated() *SessionMock_HasRegenerated_Call
HasRegenerated is a helper method to define mock.On call
func (*SessionMock_Expecter) MarkAsUnchanged ¶ added in v0.6.1
func (_e *SessionMock_Expecter) MarkAsUnchanged() *SessionMock_MarkAsUnchanged_Call
MarkAsUnchanged is a helper method to define mock.On call
func (*SessionMock_Expecter) OriginalSessionID ¶ added in v0.5.0
func (_e *SessionMock_Expecter) OriginalSessionID() *SessionMock_OriginalSessionID_Call
OriginalSessionID is a helper method to define mock.On call
func (*SessionMock_Expecter) Put ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Put(key interface{}, value interface{}) *SessionMock_Put_Call
Put is a helper method to define mock.On call
- key string
- value any
func (*SessionMock_Expecter) Regenerate ¶ added in v0.5.0
func (_e *SessionMock_Expecter) Regenerate() *SessionMock_Regenerate_Call
Regenerate is a helper method to define mock.On call
func (*SessionMock_Expecter) SessionID ¶ added in v0.5.0
func (_e *SessionMock_Expecter) SessionID() *SessionMock_SessionID_Call
SessionID is a helper method to define mock.On call
type SessionMock_ExpiresAt_Call ¶ added in v0.5.0
SessionMock_ExpiresAt_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExpiresAt'
func (*SessionMock_ExpiresAt_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_ExpiresAt_Call) Return(time1 time.Time) *SessionMock_ExpiresAt_Call
func (*SessionMock_ExpiresAt_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_ExpiresAt_Call) Run(run func()) *SessionMock_ExpiresAt_Call
func (*SessionMock_ExpiresAt_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_ExpiresAt_Call) RunAndReturn(run func() time.Time) *SessionMock_ExpiresAt_Call
type SessionMock_ExpiresSoon_Call ¶ added in v0.5.0
SessionMock_ExpiresSoon_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExpiresSoon'
func (*SessionMock_ExpiresSoon_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_ExpiresSoon_Call) Return(b bool) *SessionMock_ExpiresSoon_Call
func (*SessionMock_ExpiresSoon_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_ExpiresSoon_Call) Run(run func(delta time.Duration)) *SessionMock_ExpiresSoon_Call
func (*SessionMock_ExpiresSoon_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_ExpiresSoon_Call) RunAndReturn(run func(delta time.Duration) bool) *SessionMock_ExpiresSoon_Call
type SessionMock_Extend_Call ¶ added in v0.5.0
SessionMock_Extend_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Extend'
func (*SessionMock_Extend_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Extend_Call) Return() *SessionMock_Extend_Call
func (*SessionMock_Extend_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Extend_Call) Run(run func(expiresAt time.Time)) *SessionMock_Extend_Call
func (*SessionMock_Extend_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Extend_Call) RunAndReturn(run func(expiresAt time.Time)) *SessionMock_Extend_Call
type SessionMock_Get_Call ¶ added in v0.5.0
SessionMock_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*SessionMock_Get_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Get_Call) Return(v any, b bool) *SessionMock_Get_Call
func (*SessionMock_Get_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Get_Call) Run(run func(key string)) *SessionMock_Get_Call
func (*SessionMock_Get_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Get_Call) RunAndReturn(run func(key string) (any, bool)) *SessionMock_Get_Call
type SessionMock_HasChanged_Call ¶ added in v0.5.0
SessionMock_HasChanged_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HasChanged'
func (*SessionMock_HasChanged_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_HasChanged_Call) Return(b bool) *SessionMock_HasChanged_Call
func (*SessionMock_HasChanged_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_HasChanged_Call) Run(run func()) *SessionMock_HasChanged_Call
func (*SessionMock_HasChanged_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_HasChanged_Call) RunAndReturn(run func() bool) *SessionMock_HasChanged_Call
type SessionMock_HasExpired_Call ¶ added in v0.5.0
SessionMock_HasExpired_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HasExpired'
func (*SessionMock_HasExpired_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_HasExpired_Call) Return(b bool) *SessionMock_HasExpired_Call
func (*SessionMock_HasExpired_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_HasExpired_Call) Run(run func()) *SessionMock_HasExpired_Call
func (*SessionMock_HasExpired_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_HasExpired_Call) RunAndReturn(run func() bool) *SessionMock_HasExpired_Call
type SessionMock_HasRegenerated_Call ¶ added in v0.5.0
SessionMock_HasRegenerated_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HasRegenerated'
func (*SessionMock_HasRegenerated_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_HasRegenerated_Call) Return(b bool) *SessionMock_HasRegenerated_Call
func (*SessionMock_HasRegenerated_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_HasRegenerated_Call) Run(run func()) *SessionMock_HasRegenerated_Call
func (*SessionMock_HasRegenerated_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_HasRegenerated_Call) RunAndReturn(run func() bool) *SessionMock_HasRegenerated_Call
type SessionMock_MarkAsUnchanged_Call ¶ added in v0.6.1
SessionMock_MarkAsUnchanged_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'MarkAsUnchanged'
func (*SessionMock_MarkAsUnchanged_Call) Return ¶ added in v0.6.1
func (_c *SessionMock_MarkAsUnchanged_Call) Return() *SessionMock_MarkAsUnchanged_Call
func (*SessionMock_MarkAsUnchanged_Call) Run ¶ added in v0.6.1
func (_c *SessionMock_MarkAsUnchanged_Call) Run(run func()) *SessionMock_MarkAsUnchanged_Call
func (*SessionMock_MarkAsUnchanged_Call) RunAndReturn ¶ added in v0.6.1
func (_c *SessionMock_MarkAsUnchanged_Call) RunAndReturn(run func()) *SessionMock_MarkAsUnchanged_Call
type SessionMock_OriginalSessionID_Call ¶ added in v0.5.0
SessionMock_OriginalSessionID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'OriginalSessionID'
func (*SessionMock_OriginalSessionID_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_OriginalSessionID_Call) Return(s string) *SessionMock_OriginalSessionID_Call
func (*SessionMock_OriginalSessionID_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_OriginalSessionID_Call) Run(run func()) *SessionMock_OriginalSessionID_Call
func (*SessionMock_OriginalSessionID_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_OriginalSessionID_Call) RunAndReturn(run func() string) *SessionMock_OriginalSessionID_Call
type SessionMock_Put_Call ¶ added in v0.5.0
SessionMock_Put_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Put'
func (*SessionMock_Put_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Put_Call) Return() *SessionMock_Put_Call
func (*SessionMock_Put_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Put_Call) Run(run func(key string, value any)) *SessionMock_Put_Call
func (*SessionMock_Put_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Put_Call) RunAndReturn(run func(key string, value any)) *SessionMock_Put_Call
type SessionMock_Regenerate_Call ¶ added in v0.5.0
SessionMock_Regenerate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Regenerate'
func (*SessionMock_Regenerate_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_Regenerate_Call) Return(err error) *SessionMock_Regenerate_Call
func (*SessionMock_Regenerate_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_Regenerate_Call) Run(run func()) *SessionMock_Regenerate_Call
func (*SessionMock_Regenerate_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_Regenerate_Call) RunAndReturn(run func() error) *SessionMock_Regenerate_Call
type SessionMock_SessionID_Call ¶ added in v0.5.0
SessionMock_SessionID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SessionID'
func (*SessionMock_SessionID_Call) Return ¶ added in v0.5.0
func (_c *SessionMock_SessionID_Call) Return(s string) *SessionMock_SessionID_Call
func (*SessionMock_SessionID_Call) Run ¶ added in v0.5.0
func (_c *SessionMock_SessionID_Call) Run(run func()) *SessionMock_SessionID_Call
func (*SessionMock_SessionID_Call) RunAndReturn ¶ added in v0.5.0
func (_c *SessionMock_SessionID_Call) RunAndReturn(run func() string) *SessionMock_SessionID_Call