Documentation
¶
Index ¶
- type MockAuthStore
- func (_mock *MockAuthStore) AddAudit(ctx context.Context, a storage.AuditEntry) error
- func (_mock *MockAuthStore) AuditLog(ctx context.Context, from int64, to int64, limit int) ([]storage.AuditEntry, error)
- func (_mock *MockAuthStore) CountUsers(ctx context.Context) (int, error)
- func (_mock *MockAuthStore) CreateToken(ctx context.Context, t storage.APIToken, a storage.AuditEntry) error
- func (_mock *MockAuthStore) CreateUser(ctx context.Context, u storage.User, onlyFirst bool, a storage.AuditEntry) (int64, error)
- func (_mock *MockAuthStore) DeleteSession(ctx context.Context, tokenHash []byte, a storage.AuditEntry) error
- func (_mock *MockAuthStore) DeleteToken(ctx context.Context, id string, a storage.AuditEntry) error
- func (_mock *MockAuthStore) DeleteUser(ctx context.Context, id int64, a storage.AuditEntry) error
- func (_m *MockAuthStore) EXPECT() *MockAuthStore_Expecter
- func (_mock *MockAuthStore) PurgeSessions(ctx context.Context, idleBefore int64, createdBefore int64) error
- func (_mock *MockAuthStore) RecordLogin(ctx context.Context, r storage.LoginRecord) error
- func (_mock *MockAuthStore) Session(ctx context.Context, tokenHash []byte) (storage.Session, error)
- func (_mock *MockAuthStore) SetPassword(ctx context.Context, id int64, hash string, a storage.AuditEntry) error
- func (_mock *MockAuthStore) Token(ctx context.Context, id string) (storage.APIToken, error)
- func (_mock *MockAuthStore) Tokens(ctx context.Context) ([]storage.APIToken, error)
- func (_mock *MockAuthStore) TouchSession(ctx context.Context, tokenHash []byte, at int64) error
- func (_mock *MockAuthStore) TouchToken(ctx context.Context, id string, at int64) error
- func (_mock *MockAuthStore) UserByID(ctx context.Context, id int64) (storage.User, error)
- func (_mock *MockAuthStore) UserByName(ctx context.Context, name string) (storage.User, error)
- func (_mock *MockAuthStore) Users(ctx context.Context) ([]storage.User, error)
- type MockAuthStore_AddAudit_Call
- func (_c *MockAuthStore_AddAudit_Call) Return(err error) *MockAuthStore_AddAudit_Call
- func (_c *MockAuthStore_AddAudit_Call) Run(run func(ctx context.Context, a storage.AuditEntry)) *MockAuthStore_AddAudit_Call
- func (_c *MockAuthStore_AddAudit_Call) RunAndReturn(run func(ctx context.Context, a storage.AuditEntry) error) *MockAuthStore_AddAudit_Call
- type MockAuthStore_AuditLog_Call
- func (_c *MockAuthStore_AuditLog_Call) Return(auditEntrys []storage.AuditEntry, err error) *MockAuthStore_AuditLog_Call
- func (_c *MockAuthStore_AuditLog_Call) Run(run func(ctx context.Context, from int64, to int64, limit int)) *MockAuthStore_AuditLog_Call
- func (_c *MockAuthStore_AuditLog_Call) RunAndReturn(...) *MockAuthStore_AuditLog_Call
- type MockAuthStore_CountUsers_Call
- func (_c *MockAuthStore_CountUsers_Call) Return(n int, err error) *MockAuthStore_CountUsers_Call
- func (_c *MockAuthStore_CountUsers_Call) Run(run func(ctx context.Context)) *MockAuthStore_CountUsers_Call
- func (_c *MockAuthStore_CountUsers_Call) RunAndReturn(run func(ctx context.Context) (int, error)) *MockAuthStore_CountUsers_Call
- type MockAuthStore_CreateToken_Call
- func (_c *MockAuthStore_CreateToken_Call) Return(err error) *MockAuthStore_CreateToken_Call
- func (_c *MockAuthStore_CreateToken_Call) Run(run func(ctx context.Context, t storage.APIToken, a storage.AuditEntry)) *MockAuthStore_CreateToken_Call
- func (_c *MockAuthStore_CreateToken_Call) RunAndReturn(run func(ctx context.Context, t storage.APIToken, a storage.AuditEntry) error) *MockAuthStore_CreateToken_Call
- type MockAuthStore_CreateUser_Call
- type MockAuthStore_DeleteSession_Call
- func (_c *MockAuthStore_DeleteSession_Call) Return(err error) *MockAuthStore_DeleteSession_Call
- func (_c *MockAuthStore_DeleteSession_Call) Run(run func(ctx context.Context, tokenHash []byte, a storage.AuditEntry)) *MockAuthStore_DeleteSession_Call
- func (_c *MockAuthStore_DeleteSession_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte, a storage.AuditEntry) error) *MockAuthStore_DeleteSession_Call
- type MockAuthStore_DeleteToken_Call
- func (_c *MockAuthStore_DeleteToken_Call) Return(err error) *MockAuthStore_DeleteToken_Call
- func (_c *MockAuthStore_DeleteToken_Call) Run(run func(ctx context.Context, id string, a storage.AuditEntry)) *MockAuthStore_DeleteToken_Call
- func (_c *MockAuthStore_DeleteToken_Call) RunAndReturn(run func(ctx context.Context, id string, a storage.AuditEntry) error) *MockAuthStore_DeleteToken_Call
- type MockAuthStore_DeleteUser_Call
- func (_c *MockAuthStore_DeleteUser_Call) Return(err error) *MockAuthStore_DeleteUser_Call
- func (_c *MockAuthStore_DeleteUser_Call) Run(run func(ctx context.Context, id int64, a storage.AuditEntry)) *MockAuthStore_DeleteUser_Call
- func (_c *MockAuthStore_DeleteUser_Call) RunAndReturn(run func(ctx context.Context, id int64, a storage.AuditEntry) error) *MockAuthStore_DeleteUser_Call
- type MockAuthStore_Expecter
- func (_e *MockAuthStore_Expecter) AddAudit(ctx any, a any) *MockAuthStore_AddAudit_Call
- func (_e *MockAuthStore_Expecter) AuditLog(ctx any, from any, to any, limit any) *MockAuthStore_AuditLog_Call
- func (_e *MockAuthStore_Expecter) CountUsers(ctx any) *MockAuthStore_CountUsers_Call
- func (_e *MockAuthStore_Expecter) CreateToken(ctx any, t any, a any) *MockAuthStore_CreateToken_Call
- func (_e *MockAuthStore_Expecter) CreateUser(ctx any, u any, onlyFirst any, a any) *MockAuthStore_CreateUser_Call
- func (_e *MockAuthStore_Expecter) DeleteSession(ctx any, tokenHash any, a any) *MockAuthStore_DeleteSession_Call
- func (_e *MockAuthStore_Expecter) DeleteToken(ctx any, id any, a any) *MockAuthStore_DeleteToken_Call
- func (_e *MockAuthStore_Expecter) DeleteUser(ctx any, id any, a any) *MockAuthStore_DeleteUser_Call
- func (_e *MockAuthStore_Expecter) PurgeSessions(ctx any, idleBefore any, createdBefore any) *MockAuthStore_PurgeSessions_Call
- func (_e *MockAuthStore_Expecter) RecordLogin(ctx any, r any) *MockAuthStore_RecordLogin_Call
- func (_e *MockAuthStore_Expecter) Session(ctx any, tokenHash any) *MockAuthStore_Session_Call
- func (_e *MockAuthStore_Expecter) SetPassword(ctx any, id any, hash any, a any) *MockAuthStore_SetPassword_Call
- func (_e *MockAuthStore_Expecter) Token(ctx any, id any) *MockAuthStore_Token_Call
- func (_e *MockAuthStore_Expecter) Tokens(ctx any) *MockAuthStore_Tokens_Call
- func (_e *MockAuthStore_Expecter) TouchSession(ctx any, tokenHash any, at any) *MockAuthStore_TouchSession_Call
- func (_e *MockAuthStore_Expecter) TouchToken(ctx any, id any, at any) *MockAuthStore_TouchToken_Call
- func (_e *MockAuthStore_Expecter) UserByID(ctx any, id any) *MockAuthStore_UserByID_Call
- func (_e *MockAuthStore_Expecter) UserByName(ctx any, name any) *MockAuthStore_UserByName_Call
- func (_e *MockAuthStore_Expecter) Users(ctx any) *MockAuthStore_Users_Call
- type MockAuthStore_PurgeSessions_Call
- func (_c *MockAuthStore_PurgeSessions_Call) Return(err error) *MockAuthStore_PurgeSessions_Call
- func (_c *MockAuthStore_PurgeSessions_Call) Run(run func(ctx context.Context, idleBefore int64, createdBefore int64)) *MockAuthStore_PurgeSessions_Call
- func (_c *MockAuthStore_PurgeSessions_Call) RunAndReturn(run func(ctx context.Context, idleBefore int64, createdBefore int64) error) *MockAuthStore_PurgeSessions_Call
- type MockAuthStore_RecordLogin_Call
- func (_c *MockAuthStore_RecordLogin_Call) Return(err error) *MockAuthStore_RecordLogin_Call
- func (_c *MockAuthStore_RecordLogin_Call) Run(run func(ctx context.Context, r storage.LoginRecord)) *MockAuthStore_RecordLogin_Call
- func (_c *MockAuthStore_RecordLogin_Call) RunAndReturn(run func(ctx context.Context, r storage.LoginRecord) error) *MockAuthStore_RecordLogin_Call
- type MockAuthStore_Session_Call
- func (_c *MockAuthStore_Session_Call) Return(session storage.Session, err error) *MockAuthStore_Session_Call
- func (_c *MockAuthStore_Session_Call) Run(run func(ctx context.Context, tokenHash []byte)) *MockAuthStore_Session_Call
- func (_c *MockAuthStore_Session_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte) (storage.Session, error)) *MockAuthStore_Session_Call
- type MockAuthStore_SetPassword_Call
- func (_c *MockAuthStore_SetPassword_Call) Return(err error) *MockAuthStore_SetPassword_Call
- func (_c *MockAuthStore_SetPassword_Call) Run(run func(ctx context.Context, id int64, hash string, a storage.AuditEntry)) *MockAuthStore_SetPassword_Call
- func (_c *MockAuthStore_SetPassword_Call) RunAndReturn(...) *MockAuthStore_SetPassword_Call
- type MockAuthStore_Token_Call
- func (_c *MockAuthStore_Token_Call) Return(aPIToken storage.APIToken, err error) *MockAuthStore_Token_Call
- func (_c *MockAuthStore_Token_Call) Run(run func(ctx context.Context, id string)) *MockAuthStore_Token_Call
- func (_c *MockAuthStore_Token_Call) RunAndReturn(run func(ctx context.Context, id string) (storage.APIToken, error)) *MockAuthStore_Token_Call
- type MockAuthStore_Tokens_Call
- func (_c *MockAuthStore_Tokens_Call) Return(aPITokens []storage.APIToken, err error) *MockAuthStore_Tokens_Call
- func (_c *MockAuthStore_Tokens_Call) Run(run func(ctx context.Context)) *MockAuthStore_Tokens_Call
- func (_c *MockAuthStore_Tokens_Call) RunAndReturn(run func(ctx context.Context) ([]storage.APIToken, error)) *MockAuthStore_Tokens_Call
- type MockAuthStore_TouchSession_Call
- func (_c *MockAuthStore_TouchSession_Call) Return(err error) *MockAuthStore_TouchSession_Call
- func (_c *MockAuthStore_TouchSession_Call) Run(run func(ctx context.Context, tokenHash []byte, at int64)) *MockAuthStore_TouchSession_Call
- func (_c *MockAuthStore_TouchSession_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte, at int64) error) *MockAuthStore_TouchSession_Call
- type MockAuthStore_TouchToken_Call
- func (_c *MockAuthStore_TouchToken_Call) Return(err error) *MockAuthStore_TouchToken_Call
- func (_c *MockAuthStore_TouchToken_Call) Run(run func(ctx context.Context, id string, at int64)) *MockAuthStore_TouchToken_Call
- func (_c *MockAuthStore_TouchToken_Call) RunAndReturn(run func(ctx context.Context, id string, at int64) error) *MockAuthStore_TouchToken_Call
- type MockAuthStore_UserByID_Call
- func (_c *MockAuthStore_UserByID_Call) Return(user storage.User, err error) *MockAuthStore_UserByID_Call
- func (_c *MockAuthStore_UserByID_Call) Run(run func(ctx context.Context, id int64)) *MockAuthStore_UserByID_Call
- func (_c *MockAuthStore_UserByID_Call) RunAndReturn(run func(ctx context.Context, id int64) (storage.User, error)) *MockAuthStore_UserByID_Call
- type MockAuthStore_UserByName_Call
- func (_c *MockAuthStore_UserByName_Call) Return(user storage.User, err error) *MockAuthStore_UserByName_Call
- func (_c *MockAuthStore_UserByName_Call) Run(run func(ctx context.Context, name string)) *MockAuthStore_UserByName_Call
- func (_c *MockAuthStore_UserByName_Call) RunAndReturn(run func(ctx context.Context, name string) (storage.User, error)) *MockAuthStore_UserByName_Call
- type MockAuthStore_Users_Call
- func (_c *MockAuthStore_Users_Call) Return(users []storage.User, err error) *MockAuthStore_Users_Call
- func (_c *MockAuthStore_Users_Call) Run(run func(ctx context.Context)) *MockAuthStore_Users_Call
- func (_c *MockAuthStore_Users_Call) RunAndReturn(run func(ctx context.Context) ([]storage.User, error)) *MockAuthStore_Users_Call
- type MockCollectorStore
- func (_mock *MockCollectorStore) AddStatus(ctx context.Context, events []storage.StatusEvent) error
- func (_mock *MockCollectorStore) CounterStates(ctx context.Context, ids []int64) (map[int64]storage.CounterState, error)
- func (_m *MockCollectorStore) EXPECT() *MockCollectorStore_Expecter
- func (_mock *MockCollectorStore) EnsureSeries(ctx context.Context, slot int64, defs []storage.SeriesDef) (map[storage.SeriesKey]int64, error)
- func (_mock *MockCollectorStore) Flush(ctx context.Context, b storage.Batch) error
- func (_mock *MockCollectorStore) LastStatus(ctx context.Context, device string) (map[string]storage.StatusEvent, error)
- type MockCollectorStore_AddStatus_Call
- func (_c *MockCollectorStore_AddStatus_Call) Return(err error) *MockCollectorStore_AddStatus_Call
- func (_c *MockCollectorStore_AddStatus_Call) Run(run func(ctx context.Context, events []storage.StatusEvent)) *MockCollectorStore_AddStatus_Call
- func (_c *MockCollectorStore_AddStatus_Call) RunAndReturn(run func(ctx context.Context, events []storage.StatusEvent) error) *MockCollectorStore_AddStatus_Call
- type MockCollectorStore_CounterStates_Call
- func (_c *MockCollectorStore_CounterStates_Call) Return(int64ToCounterState map[int64]storage.CounterState, err error) *MockCollectorStore_CounterStates_Call
- func (_c *MockCollectorStore_CounterStates_Call) Run(run func(ctx context.Context, ids []int64)) *MockCollectorStore_CounterStates_Call
- func (_c *MockCollectorStore_CounterStates_Call) RunAndReturn(...) *MockCollectorStore_CounterStates_Call
- type MockCollectorStore_EnsureSeries_Call
- func (_c *MockCollectorStore_EnsureSeries_Call) Return(seriesKeyToInt64 map[storage.SeriesKey]int64, err error) *MockCollectorStore_EnsureSeries_Call
- func (_c *MockCollectorStore_EnsureSeries_Call) Run(run func(ctx context.Context, slot int64, defs []storage.SeriesDef)) *MockCollectorStore_EnsureSeries_Call
- func (_c *MockCollectorStore_EnsureSeries_Call) RunAndReturn(...) *MockCollectorStore_EnsureSeries_Call
- type MockCollectorStore_Expecter
- func (_e *MockCollectorStore_Expecter) AddStatus(ctx any, events any) *MockCollectorStore_AddStatus_Call
- func (_e *MockCollectorStore_Expecter) CounterStates(ctx any, ids any) *MockCollectorStore_CounterStates_Call
- func (_e *MockCollectorStore_Expecter) EnsureSeries(ctx any, slot any, defs any) *MockCollectorStore_EnsureSeries_Call
- func (_e *MockCollectorStore_Expecter) Flush(ctx any, b any) *MockCollectorStore_Flush_Call
- func (_e *MockCollectorStore_Expecter) LastStatus(ctx any, device any) *MockCollectorStore_LastStatus_Call
- type MockCollectorStore_Flush_Call
- func (_c *MockCollectorStore_Flush_Call) Return(err error) *MockCollectorStore_Flush_Call
- func (_c *MockCollectorStore_Flush_Call) Run(run func(ctx context.Context, b storage.Batch)) *MockCollectorStore_Flush_Call
- func (_c *MockCollectorStore_Flush_Call) RunAndReturn(run func(ctx context.Context, b storage.Batch) error) *MockCollectorStore_Flush_Call
- type MockCollectorStore_LastStatus_Call
- func (_c *MockCollectorStore_LastStatus_Call) Return(stringToStatusEvent map[string]storage.StatusEvent, err error) *MockCollectorStore_LastStatus_Call
- func (_c *MockCollectorStore_LastStatus_Call) Run(run func(ctx context.Context, device string)) *MockCollectorStore_LastStatus_Call
- func (_c *MockCollectorStore_LastStatus_Call) RunAndReturn(...) *MockCollectorStore_LastStatus_Call
- type MockConfigStore
- type MockConfigStore_ApplyConfig_Call
- func (_c *MockConfigStore_ApplyConfig_Call) Return(n int64, err error) *MockConfigStore_ApplyConfig_Call
- func (_c *MockConfigStore_ApplyConfig_Call) Run(run func(ctx context.Context, c storage.ConfigChange)) *MockConfigStore_ApplyConfig_Call
- func (_c *MockConfigStore_ApplyConfig_Call) RunAndReturn(run func(ctx context.Context, c storage.ConfigChange) (int64, error)) *MockConfigStore_ApplyConfig_Call
- type MockConfigStore_ConfigState_Call
- func (_c *MockConfigStore_ConfigState_Call) Return(configState storage.ConfigState, err error) *MockConfigStore_ConfigState_Call
- func (_c *MockConfigStore_ConfigState_Call) Run(run func(ctx context.Context)) *MockConfigStore_ConfigState_Call
- func (_c *MockConfigStore_ConfigState_Call) RunAndReturn(run func(ctx context.Context) (storage.ConfigState, error)) *MockConfigStore_ConfigState_Call
- type MockConfigStore_Expecter
- type MockDeriveStore
- func (_mock *MockDeriveStore) CacheGen() int64
- func (_mock *MockDeriveStore) CacheGet(ctx context.Context, keys []string, configRev int64) (map[string]string, error)
- func (_mock *MockDeriveStore) CachePut(ctx context.Context, configRev int64, gen int64, entries map[string]string) error
- func (_m *MockDeriveStore) EXPECT() *MockDeriveStore_Expecter
- type MockDeriveStore_CacheGen_Call
- type MockDeriveStore_CacheGet_Call
- func (_c *MockDeriveStore_CacheGet_Call) Return(stringToString map[string]string, err error) *MockDeriveStore_CacheGet_Call
- func (_c *MockDeriveStore_CacheGet_Call) Run(run func(ctx context.Context, keys []string, configRev int64)) *MockDeriveStore_CacheGet_Call
- func (_c *MockDeriveStore_CacheGet_Call) RunAndReturn(...) *MockDeriveStore_CacheGet_Call
- type MockDeriveStore_CachePut_Call
- type MockDeriveStore_Expecter
- func (_e *MockDeriveStore_Expecter) CacheGen() *MockDeriveStore_CacheGen_Call
- func (_e *MockDeriveStore_Expecter) CacheGet(ctx any, keys any, configRev any) *MockDeriveStore_CacheGet_Call
- func (_e *MockDeriveStore_Expecter) CachePut(ctx any, configRev any, gen any, entries any) *MockDeriveStore_CachePut_Call
- type MockImportStore
- func (_m *MockImportStore) EXPECT() *MockImportStore_Expecter
- func (_mock *MockImportStore) FirstSlot(ctx context.Context) (int64, bool, error)
- func (_mock *MockImportStore) Import(ctx context.Context, b storage.ImportBatch) error
- func (_mock *MockImportStore) ImportSource(ctx context.Context) (string, error)
- type MockImportStore_Expecter
- type MockImportStore_FirstSlot_Call
- func (_c *MockImportStore_FirstSlot_Call) Return(slot int64, ok bool, err error) *MockImportStore_FirstSlot_Call
- func (_c *MockImportStore_FirstSlot_Call) Run(run func(ctx context.Context)) *MockImportStore_FirstSlot_Call
- func (_c *MockImportStore_FirstSlot_Call) RunAndReturn(run func(ctx context.Context) (int64, bool, error)) *MockImportStore_FirstSlot_Call
- type MockImportStore_ImportSource_Call
- func (_c *MockImportStore_ImportSource_Call) Return(s string, err error) *MockImportStore_ImportSource_Call
- func (_c *MockImportStore_ImportSource_Call) Run(run func(ctx context.Context)) *MockImportStore_ImportSource_Call
- func (_c *MockImportStore_ImportSource_Call) RunAndReturn(run func(ctx context.Context) (string, error)) *MockImportStore_ImportSource_Call
- type MockImportStore_Import_Call
- func (_c *MockImportStore_Import_Call) Return(err error) *MockImportStore_Import_Call
- func (_c *MockImportStore_Import_Call) Run(run func(ctx context.Context, b storage.ImportBatch)) *MockImportStore_Import_Call
- func (_c *MockImportStore_Import_Call) RunAndReturn(run func(ctx context.Context, b storage.ImportBatch) error) *MockImportStore_Import_Call
- type MockReadStore
- func (_mock *MockReadStore) Carry(ctx context.Context, ids []int64) (map[int64]float64, error)
- func (_m *MockReadStore) EXPECT() *MockReadStore_Expecter
- func (_mock *MockReadStore) EnergyBuckets(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.EnergyBucket, error)
- func (_mock *MockReadStore) FirstSlot(ctx context.Context) (int64, bool, error)
- func (_mock *MockReadStore) GaugeBuckets(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.GaugeBucket, error)
- func (_mock *MockReadStore) SeriesID(ctx context.Context, key storage.SeriesKey) (int64, error)
- func (_mock *MockReadStore) StatusEvents(ctx context.Context, device string, from int64, to int64, limit int) ([]storage.StatusEvent, error)
- func (_mock *MockReadStore) SumEnergy(ctx context.Context, seriesID int64, from int64, to int64) (storage.EnergyTotal, error)
- func (_mock *MockReadStore) SumEnergyMany(ctx context.Context, ids []int64, from int64, to int64, closedBefore int64) (map[int64]storage.EnergySum, error)
- type MockReadStore_Carry_Call
- func (_c *MockReadStore_Carry_Call) Return(int64ToFloat64 map[int64]float64, err error) *MockReadStore_Carry_Call
- func (_c *MockReadStore_Carry_Call) Run(run func(ctx context.Context, ids []int64)) *MockReadStore_Carry_Call
- func (_c *MockReadStore_Carry_Call) RunAndReturn(run func(ctx context.Context, ids []int64) (map[int64]float64, error)) *MockReadStore_Carry_Call
- type MockReadStore_EnergyBuckets_Call
- func (_c *MockReadStore_EnergyBuckets_Call) Return(energyBuckets []storage.EnergyBucket, err error) *MockReadStore_EnergyBuckets_Call
- func (_c *MockReadStore_EnergyBuckets_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_EnergyBuckets_Call
- func (_c *MockReadStore_EnergyBuckets_Call) RunAndReturn(...) *MockReadStore_EnergyBuckets_Call
- type MockReadStore_Expecter
- func (_e *MockReadStore_Expecter) Carry(ctx any, ids any) *MockReadStore_Carry_Call
- func (_e *MockReadStore_Expecter) EnergyBuckets(ctx any, seriesID any, from any, to any) *MockReadStore_EnergyBuckets_Call
- func (_e *MockReadStore_Expecter) FirstSlot(ctx any) *MockReadStore_FirstSlot_Call
- func (_e *MockReadStore_Expecter) GaugeBuckets(ctx any, seriesID any, from any, to any) *MockReadStore_GaugeBuckets_Call
- func (_e *MockReadStore_Expecter) SeriesID(ctx any, key any) *MockReadStore_SeriesID_Call
- func (_e *MockReadStore_Expecter) StatusEvents(ctx any, device any, from any, to any, limit any) *MockReadStore_StatusEvents_Call
- func (_e *MockReadStore_Expecter) SumEnergy(ctx any, seriesID any, from any, to any) *MockReadStore_SumEnergy_Call
- func (_e *MockReadStore_Expecter) SumEnergyMany(ctx any, ids any, from any, to any, closedBefore any) *MockReadStore_SumEnergyMany_Call
- type MockReadStore_FirstSlot_Call
- func (_c *MockReadStore_FirstSlot_Call) Return(slot int64, ok bool, err error) *MockReadStore_FirstSlot_Call
- func (_c *MockReadStore_FirstSlot_Call) Run(run func(ctx context.Context)) *MockReadStore_FirstSlot_Call
- func (_c *MockReadStore_FirstSlot_Call) RunAndReturn(run func(ctx context.Context) (int64, bool, error)) *MockReadStore_FirstSlot_Call
- type MockReadStore_GaugeBuckets_Call
- func (_c *MockReadStore_GaugeBuckets_Call) Return(gaugeBuckets []storage.GaugeBucket, err error) *MockReadStore_GaugeBuckets_Call
- func (_c *MockReadStore_GaugeBuckets_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_GaugeBuckets_Call
- func (_c *MockReadStore_GaugeBuckets_Call) RunAndReturn(...) *MockReadStore_GaugeBuckets_Call
- type MockReadStore_SeriesID_Call
- func (_c *MockReadStore_SeriesID_Call) Return(n int64, err error) *MockReadStore_SeriesID_Call
- func (_c *MockReadStore_SeriesID_Call) Run(run func(ctx context.Context, key storage.SeriesKey)) *MockReadStore_SeriesID_Call
- func (_c *MockReadStore_SeriesID_Call) RunAndReturn(run func(ctx context.Context, key storage.SeriesKey) (int64, error)) *MockReadStore_SeriesID_Call
- type MockReadStore_StatusEvents_Call
- func (_c *MockReadStore_StatusEvents_Call) Return(statusEvents []storage.StatusEvent, err error) *MockReadStore_StatusEvents_Call
- func (_c *MockReadStore_StatusEvents_Call) Run(run func(ctx context.Context, device string, from int64, to int64, limit int)) *MockReadStore_StatusEvents_Call
- func (_c *MockReadStore_StatusEvents_Call) RunAndReturn(...) *MockReadStore_StatusEvents_Call
- type MockReadStore_SumEnergyMany_Call
- func (_c *MockReadStore_SumEnergyMany_Call) Return(int64ToEnergySum map[int64]storage.EnergySum, err error) *MockReadStore_SumEnergyMany_Call
- func (_c *MockReadStore_SumEnergyMany_Call) Run(...) *MockReadStore_SumEnergyMany_Call
- func (_c *MockReadStore_SumEnergyMany_Call) RunAndReturn(...) *MockReadStore_SumEnergyMany_Call
- type MockReadStore_SumEnergy_Call
- func (_c *MockReadStore_SumEnergy_Call) Return(energyTotal storage.EnergyTotal, err error) *MockReadStore_SumEnergy_Call
- func (_c *MockReadStore_SumEnergy_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_SumEnergy_Call
- func (_c *MockReadStore_SumEnergy_Call) RunAndReturn(...) *MockReadStore_SumEnergy_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockAuthStore ¶
MockAuthStore is an autogenerated mock type for the AuthStore type
func NewMockAuthStore ¶
func NewMockAuthStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockAuthStore
NewMockAuthStore creates a new instance of MockAuthStore. 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 (*MockAuthStore) AddAudit ¶
func (_mock *MockAuthStore) AddAudit(ctx context.Context, a storage.AuditEntry) error
AddAudit provides a mock function for the type MockAuthStore
func (*MockAuthStore) AuditLog ¶
func (_mock *MockAuthStore) AuditLog(ctx context.Context, from int64, to int64, limit int) ([]storage.AuditEntry, error)
AuditLog provides a mock function for the type MockAuthStore
func (*MockAuthStore) CountUsers ¶
func (_mock *MockAuthStore) CountUsers(ctx context.Context) (int, error)
CountUsers provides a mock function for the type MockAuthStore
func (*MockAuthStore) CreateToken ¶
func (_mock *MockAuthStore) CreateToken(ctx context.Context, t storage.APIToken, a storage.AuditEntry) error
CreateToken provides a mock function for the type MockAuthStore
func (*MockAuthStore) CreateUser ¶
func (_mock *MockAuthStore) CreateUser(ctx context.Context, u storage.User, onlyFirst bool, a storage.AuditEntry) (int64, error)
CreateUser provides a mock function for the type MockAuthStore
func (*MockAuthStore) DeleteSession ¶
func (_mock *MockAuthStore) DeleteSession(ctx context.Context, tokenHash []byte, a storage.AuditEntry) error
DeleteSession provides a mock function for the type MockAuthStore
func (*MockAuthStore) DeleteToken ¶
func (_mock *MockAuthStore) DeleteToken(ctx context.Context, id string, a storage.AuditEntry) error
DeleteToken provides a mock function for the type MockAuthStore
func (*MockAuthStore) DeleteUser ¶
func (_mock *MockAuthStore) DeleteUser(ctx context.Context, id int64, a storage.AuditEntry) error
DeleteUser provides a mock function for the type MockAuthStore
func (*MockAuthStore) EXPECT ¶
func (_m *MockAuthStore) EXPECT() *MockAuthStore_Expecter
func (*MockAuthStore) PurgeSessions ¶
func (_mock *MockAuthStore) PurgeSessions(ctx context.Context, idleBefore int64, createdBefore int64) error
PurgeSessions provides a mock function for the type MockAuthStore
func (*MockAuthStore) RecordLogin ¶
func (_mock *MockAuthStore) RecordLogin(ctx context.Context, r storage.LoginRecord) error
RecordLogin provides a mock function for the type MockAuthStore
func (*MockAuthStore) SetPassword ¶
func (_mock *MockAuthStore) SetPassword(ctx context.Context, id int64, hash string, a storage.AuditEntry) error
SetPassword provides a mock function for the type MockAuthStore
func (*MockAuthStore) TouchSession ¶
TouchSession provides a mock function for the type MockAuthStore
func (*MockAuthStore) TouchToken ¶
TouchToken provides a mock function for the type MockAuthStore
func (*MockAuthStore) UserByName ¶
UserByName provides a mock function for the type MockAuthStore
type MockAuthStore_AddAudit_Call ¶
MockAuthStore_AddAudit_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AddAudit'
func (*MockAuthStore_AddAudit_Call) Return ¶
func (_c *MockAuthStore_AddAudit_Call) Return(err error) *MockAuthStore_AddAudit_Call
func (*MockAuthStore_AddAudit_Call) Run ¶
func (_c *MockAuthStore_AddAudit_Call) Run(run func(ctx context.Context, a storage.AuditEntry)) *MockAuthStore_AddAudit_Call
func (*MockAuthStore_AddAudit_Call) RunAndReturn ¶
func (_c *MockAuthStore_AddAudit_Call) RunAndReturn(run func(ctx context.Context, a storage.AuditEntry) error) *MockAuthStore_AddAudit_Call
type MockAuthStore_AuditLog_Call ¶
MockAuthStore_AuditLog_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AuditLog'
func (*MockAuthStore_AuditLog_Call) Return ¶
func (_c *MockAuthStore_AuditLog_Call) Return(auditEntrys []storage.AuditEntry, err error) *MockAuthStore_AuditLog_Call
func (*MockAuthStore_AuditLog_Call) Run ¶
func (_c *MockAuthStore_AuditLog_Call) Run(run func(ctx context.Context, from int64, to int64, limit int)) *MockAuthStore_AuditLog_Call
func (*MockAuthStore_AuditLog_Call) RunAndReturn ¶
func (_c *MockAuthStore_AuditLog_Call) RunAndReturn(run func(ctx context.Context, from int64, to int64, limit int) ([]storage.AuditEntry, error)) *MockAuthStore_AuditLog_Call
type MockAuthStore_CountUsers_Call ¶
MockAuthStore_CountUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CountUsers'
func (*MockAuthStore_CountUsers_Call) Return ¶
func (_c *MockAuthStore_CountUsers_Call) Return(n int, err error) *MockAuthStore_CountUsers_Call
func (*MockAuthStore_CountUsers_Call) Run ¶
func (_c *MockAuthStore_CountUsers_Call) Run(run func(ctx context.Context)) *MockAuthStore_CountUsers_Call
func (*MockAuthStore_CountUsers_Call) RunAndReturn ¶
func (_c *MockAuthStore_CountUsers_Call) RunAndReturn(run func(ctx context.Context) (int, error)) *MockAuthStore_CountUsers_Call
type MockAuthStore_CreateToken_Call ¶
MockAuthStore_CreateToken_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateToken'
func (*MockAuthStore_CreateToken_Call) Return ¶
func (_c *MockAuthStore_CreateToken_Call) Return(err error) *MockAuthStore_CreateToken_Call
func (*MockAuthStore_CreateToken_Call) Run ¶
func (_c *MockAuthStore_CreateToken_Call) Run(run func(ctx context.Context, t storage.APIToken, a storage.AuditEntry)) *MockAuthStore_CreateToken_Call
func (*MockAuthStore_CreateToken_Call) RunAndReturn ¶
func (_c *MockAuthStore_CreateToken_Call) RunAndReturn(run func(ctx context.Context, t storage.APIToken, a storage.AuditEntry) error) *MockAuthStore_CreateToken_Call
type MockAuthStore_CreateUser_Call ¶
MockAuthStore_CreateUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateUser'
func (*MockAuthStore_CreateUser_Call) Return ¶
func (_c *MockAuthStore_CreateUser_Call) Return(n int64, err error) *MockAuthStore_CreateUser_Call
func (*MockAuthStore_CreateUser_Call) Run ¶
func (_c *MockAuthStore_CreateUser_Call) Run(run func(ctx context.Context, u storage.User, onlyFirst bool, a storage.AuditEntry)) *MockAuthStore_CreateUser_Call
func (*MockAuthStore_CreateUser_Call) RunAndReturn ¶
func (_c *MockAuthStore_CreateUser_Call) RunAndReturn(run func(ctx context.Context, u storage.User, onlyFirst bool, a storage.AuditEntry) (int64, error)) *MockAuthStore_CreateUser_Call
type MockAuthStore_DeleteSession_Call ¶
MockAuthStore_DeleteSession_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteSession'
func (*MockAuthStore_DeleteSession_Call) Return ¶
func (_c *MockAuthStore_DeleteSession_Call) Return(err error) *MockAuthStore_DeleteSession_Call
func (*MockAuthStore_DeleteSession_Call) Run ¶
func (_c *MockAuthStore_DeleteSession_Call) Run(run func(ctx context.Context, tokenHash []byte, a storage.AuditEntry)) *MockAuthStore_DeleteSession_Call
func (*MockAuthStore_DeleteSession_Call) RunAndReturn ¶
func (_c *MockAuthStore_DeleteSession_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte, a storage.AuditEntry) error) *MockAuthStore_DeleteSession_Call
type MockAuthStore_DeleteToken_Call ¶
MockAuthStore_DeleteToken_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteToken'
func (*MockAuthStore_DeleteToken_Call) Return ¶
func (_c *MockAuthStore_DeleteToken_Call) Return(err error) *MockAuthStore_DeleteToken_Call
func (*MockAuthStore_DeleteToken_Call) Run ¶
func (_c *MockAuthStore_DeleteToken_Call) Run(run func(ctx context.Context, id string, a storage.AuditEntry)) *MockAuthStore_DeleteToken_Call
func (*MockAuthStore_DeleteToken_Call) RunAndReturn ¶
func (_c *MockAuthStore_DeleteToken_Call) RunAndReturn(run func(ctx context.Context, id string, a storage.AuditEntry) error) *MockAuthStore_DeleteToken_Call
type MockAuthStore_DeleteUser_Call ¶
MockAuthStore_DeleteUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteUser'
func (*MockAuthStore_DeleteUser_Call) Return ¶
func (_c *MockAuthStore_DeleteUser_Call) Return(err error) *MockAuthStore_DeleteUser_Call
func (*MockAuthStore_DeleteUser_Call) Run ¶
func (_c *MockAuthStore_DeleteUser_Call) Run(run func(ctx context.Context, id int64, a storage.AuditEntry)) *MockAuthStore_DeleteUser_Call
func (*MockAuthStore_DeleteUser_Call) RunAndReturn ¶
func (_c *MockAuthStore_DeleteUser_Call) RunAndReturn(run func(ctx context.Context, id int64, a storage.AuditEntry) error) *MockAuthStore_DeleteUser_Call
type MockAuthStore_Expecter ¶
type MockAuthStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockAuthStore_Expecter) AddAudit ¶
func (_e *MockAuthStore_Expecter) AddAudit(ctx any, a any) *MockAuthStore_AddAudit_Call
AddAudit is a helper method to define mock.On call
- ctx context.Context
- a storage.AuditEntry
func (*MockAuthStore_Expecter) AuditLog ¶
func (_e *MockAuthStore_Expecter) AuditLog(ctx any, from any, to any, limit any) *MockAuthStore_AuditLog_Call
AuditLog is a helper method to define mock.On call
- ctx context.Context
- from int64
- to int64
- limit int
func (*MockAuthStore_Expecter) CountUsers ¶
func (_e *MockAuthStore_Expecter) CountUsers(ctx any) *MockAuthStore_CountUsers_Call
CountUsers is a helper method to define mock.On call
- ctx context.Context
func (*MockAuthStore_Expecter) CreateToken ¶
func (_e *MockAuthStore_Expecter) CreateToken(ctx any, t any, a any) *MockAuthStore_CreateToken_Call
CreateToken is a helper method to define mock.On call
- ctx context.Context
- t storage.APIToken
- a storage.AuditEntry
func (*MockAuthStore_Expecter) CreateUser ¶
func (_e *MockAuthStore_Expecter) CreateUser(ctx any, u any, onlyFirst any, a any) *MockAuthStore_CreateUser_Call
CreateUser is a helper method to define mock.On call
- ctx context.Context
- u storage.User
- onlyFirst bool
- a storage.AuditEntry
func (*MockAuthStore_Expecter) DeleteSession ¶
func (_e *MockAuthStore_Expecter) DeleteSession(ctx any, tokenHash any, a any) *MockAuthStore_DeleteSession_Call
DeleteSession is a helper method to define mock.On call
- ctx context.Context
- tokenHash []byte
- a storage.AuditEntry
func (*MockAuthStore_Expecter) DeleteToken ¶
func (_e *MockAuthStore_Expecter) DeleteToken(ctx any, id any, a any) *MockAuthStore_DeleteToken_Call
DeleteToken is a helper method to define mock.On call
- ctx context.Context
- id string
- a storage.AuditEntry
func (*MockAuthStore_Expecter) DeleteUser ¶
func (_e *MockAuthStore_Expecter) DeleteUser(ctx any, id any, a any) *MockAuthStore_DeleteUser_Call
DeleteUser is a helper method to define mock.On call
- ctx context.Context
- id int64
- a storage.AuditEntry
func (*MockAuthStore_Expecter) PurgeSessions ¶
func (_e *MockAuthStore_Expecter) PurgeSessions(ctx any, idleBefore any, createdBefore any) *MockAuthStore_PurgeSessions_Call
PurgeSessions is a helper method to define mock.On call
- ctx context.Context
- idleBefore int64
- createdBefore int64
func (*MockAuthStore_Expecter) RecordLogin ¶
func (_e *MockAuthStore_Expecter) RecordLogin(ctx any, r any) *MockAuthStore_RecordLogin_Call
RecordLogin is a helper method to define mock.On call
- ctx context.Context
- r storage.LoginRecord
func (*MockAuthStore_Expecter) Session ¶
func (_e *MockAuthStore_Expecter) Session(ctx any, tokenHash any) *MockAuthStore_Session_Call
Session is a helper method to define mock.On call
- ctx context.Context
- tokenHash []byte
func (*MockAuthStore_Expecter) SetPassword ¶
func (_e *MockAuthStore_Expecter) SetPassword(ctx any, id any, hash any, a any) *MockAuthStore_SetPassword_Call
SetPassword is a helper method to define mock.On call
- ctx context.Context
- id int64
- hash string
- a storage.AuditEntry
func (*MockAuthStore_Expecter) Token ¶
func (_e *MockAuthStore_Expecter) Token(ctx any, id any) *MockAuthStore_Token_Call
Token is a helper method to define mock.On call
- ctx context.Context
- id string
func (*MockAuthStore_Expecter) Tokens ¶
func (_e *MockAuthStore_Expecter) Tokens(ctx any) *MockAuthStore_Tokens_Call
Tokens is a helper method to define mock.On call
- ctx context.Context
func (*MockAuthStore_Expecter) TouchSession ¶
func (_e *MockAuthStore_Expecter) TouchSession(ctx any, tokenHash any, at any) *MockAuthStore_TouchSession_Call
TouchSession is a helper method to define mock.On call
- ctx context.Context
- tokenHash []byte
- at int64
func (*MockAuthStore_Expecter) TouchToken ¶
func (_e *MockAuthStore_Expecter) TouchToken(ctx any, id any, at any) *MockAuthStore_TouchToken_Call
TouchToken is a helper method to define mock.On call
- ctx context.Context
- id string
- at int64
func (*MockAuthStore_Expecter) UserByID ¶
func (_e *MockAuthStore_Expecter) UserByID(ctx any, id any) *MockAuthStore_UserByID_Call
UserByID is a helper method to define mock.On call
- ctx context.Context
- id int64
func (*MockAuthStore_Expecter) UserByName ¶
func (_e *MockAuthStore_Expecter) UserByName(ctx any, name any) *MockAuthStore_UserByName_Call
UserByName is a helper method to define mock.On call
- ctx context.Context
- name string
func (*MockAuthStore_Expecter) Users ¶
func (_e *MockAuthStore_Expecter) Users(ctx any) *MockAuthStore_Users_Call
Users is a helper method to define mock.On call
- ctx context.Context
type MockAuthStore_PurgeSessions_Call ¶
MockAuthStore_PurgeSessions_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PurgeSessions'
func (*MockAuthStore_PurgeSessions_Call) Return ¶
func (_c *MockAuthStore_PurgeSessions_Call) Return(err error) *MockAuthStore_PurgeSessions_Call
func (*MockAuthStore_PurgeSessions_Call) Run ¶
func (_c *MockAuthStore_PurgeSessions_Call) Run(run func(ctx context.Context, idleBefore int64, createdBefore int64)) *MockAuthStore_PurgeSessions_Call
func (*MockAuthStore_PurgeSessions_Call) RunAndReturn ¶
func (_c *MockAuthStore_PurgeSessions_Call) RunAndReturn(run func(ctx context.Context, idleBefore int64, createdBefore int64) error) *MockAuthStore_PurgeSessions_Call
type MockAuthStore_RecordLogin_Call ¶
MockAuthStore_RecordLogin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RecordLogin'
func (*MockAuthStore_RecordLogin_Call) Return ¶
func (_c *MockAuthStore_RecordLogin_Call) Return(err error) *MockAuthStore_RecordLogin_Call
func (*MockAuthStore_RecordLogin_Call) Run ¶
func (_c *MockAuthStore_RecordLogin_Call) Run(run func(ctx context.Context, r storage.LoginRecord)) *MockAuthStore_RecordLogin_Call
func (*MockAuthStore_RecordLogin_Call) RunAndReturn ¶
func (_c *MockAuthStore_RecordLogin_Call) RunAndReturn(run func(ctx context.Context, r storage.LoginRecord) error) *MockAuthStore_RecordLogin_Call
type MockAuthStore_Session_Call ¶
MockAuthStore_Session_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Session'
func (*MockAuthStore_Session_Call) Return ¶
func (_c *MockAuthStore_Session_Call) Return(session storage.Session, err error) *MockAuthStore_Session_Call
func (*MockAuthStore_Session_Call) Run ¶
func (_c *MockAuthStore_Session_Call) Run(run func(ctx context.Context, tokenHash []byte)) *MockAuthStore_Session_Call
func (*MockAuthStore_Session_Call) RunAndReturn ¶
func (_c *MockAuthStore_Session_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte) (storage.Session, error)) *MockAuthStore_Session_Call
type MockAuthStore_SetPassword_Call ¶
MockAuthStore_SetPassword_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetPassword'
func (*MockAuthStore_SetPassword_Call) Return ¶
func (_c *MockAuthStore_SetPassword_Call) Return(err error) *MockAuthStore_SetPassword_Call
func (*MockAuthStore_SetPassword_Call) Run ¶
func (_c *MockAuthStore_SetPassword_Call) Run(run func(ctx context.Context, id int64, hash string, a storage.AuditEntry)) *MockAuthStore_SetPassword_Call
func (*MockAuthStore_SetPassword_Call) RunAndReturn ¶
func (_c *MockAuthStore_SetPassword_Call) RunAndReturn(run func(ctx context.Context, id int64, hash string, a storage.AuditEntry) error) *MockAuthStore_SetPassword_Call
type MockAuthStore_Token_Call ¶
MockAuthStore_Token_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Token'
func (*MockAuthStore_Token_Call) Return ¶
func (_c *MockAuthStore_Token_Call) Return(aPIToken storage.APIToken, err error) *MockAuthStore_Token_Call
func (*MockAuthStore_Token_Call) Run ¶
func (_c *MockAuthStore_Token_Call) Run(run func(ctx context.Context, id string)) *MockAuthStore_Token_Call
func (*MockAuthStore_Token_Call) RunAndReturn ¶
func (_c *MockAuthStore_Token_Call) RunAndReturn(run func(ctx context.Context, id string) (storage.APIToken, error)) *MockAuthStore_Token_Call
type MockAuthStore_Tokens_Call ¶
MockAuthStore_Tokens_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Tokens'
func (*MockAuthStore_Tokens_Call) Return ¶
func (_c *MockAuthStore_Tokens_Call) Return(aPITokens []storage.APIToken, err error) *MockAuthStore_Tokens_Call
func (*MockAuthStore_Tokens_Call) Run ¶
func (_c *MockAuthStore_Tokens_Call) Run(run func(ctx context.Context)) *MockAuthStore_Tokens_Call
func (*MockAuthStore_Tokens_Call) RunAndReturn ¶
func (_c *MockAuthStore_Tokens_Call) RunAndReturn(run func(ctx context.Context) ([]storage.APIToken, error)) *MockAuthStore_Tokens_Call
type MockAuthStore_TouchSession_Call ¶
MockAuthStore_TouchSession_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TouchSession'
func (*MockAuthStore_TouchSession_Call) Return ¶
func (_c *MockAuthStore_TouchSession_Call) Return(err error) *MockAuthStore_TouchSession_Call
func (*MockAuthStore_TouchSession_Call) Run ¶
func (_c *MockAuthStore_TouchSession_Call) Run(run func(ctx context.Context, tokenHash []byte, at int64)) *MockAuthStore_TouchSession_Call
func (*MockAuthStore_TouchSession_Call) RunAndReturn ¶
func (_c *MockAuthStore_TouchSession_Call) RunAndReturn(run func(ctx context.Context, tokenHash []byte, at int64) error) *MockAuthStore_TouchSession_Call
type MockAuthStore_TouchToken_Call ¶
MockAuthStore_TouchToken_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TouchToken'
func (*MockAuthStore_TouchToken_Call) Return ¶
func (_c *MockAuthStore_TouchToken_Call) Return(err error) *MockAuthStore_TouchToken_Call
func (*MockAuthStore_TouchToken_Call) Run ¶
func (_c *MockAuthStore_TouchToken_Call) Run(run func(ctx context.Context, id string, at int64)) *MockAuthStore_TouchToken_Call
func (*MockAuthStore_TouchToken_Call) RunAndReturn ¶
func (_c *MockAuthStore_TouchToken_Call) RunAndReturn(run func(ctx context.Context, id string, at int64) error) *MockAuthStore_TouchToken_Call
type MockAuthStore_UserByID_Call ¶
MockAuthStore_UserByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UserByID'
func (*MockAuthStore_UserByID_Call) Return ¶
func (_c *MockAuthStore_UserByID_Call) Return(user storage.User, err error) *MockAuthStore_UserByID_Call
func (*MockAuthStore_UserByID_Call) Run ¶
func (_c *MockAuthStore_UserByID_Call) Run(run func(ctx context.Context, id int64)) *MockAuthStore_UserByID_Call
func (*MockAuthStore_UserByID_Call) RunAndReturn ¶
func (_c *MockAuthStore_UserByID_Call) RunAndReturn(run func(ctx context.Context, id int64) (storage.User, error)) *MockAuthStore_UserByID_Call
type MockAuthStore_UserByName_Call ¶
MockAuthStore_UserByName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UserByName'
func (*MockAuthStore_UserByName_Call) Return ¶
func (_c *MockAuthStore_UserByName_Call) Return(user storage.User, err error) *MockAuthStore_UserByName_Call
func (*MockAuthStore_UserByName_Call) Run ¶
func (_c *MockAuthStore_UserByName_Call) Run(run func(ctx context.Context, name string)) *MockAuthStore_UserByName_Call
func (*MockAuthStore_UserByName_Call) RunAndReturn ¶
func (_c *MockAuthStore_UserByName_Call) RunAndReturn(run func(ctx context.Context, name string) (storage.User, error)) *MockAuthStore_UserByName_Call
type MockAuthStore_Users_Call ¶
MockAuthStore_Users_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Users'
func (*MockAuthStore_Users_Call) Return ¶
func (_c *MockAuthStore_Users_Call) Return(users []storage.User, err error) *MockAuthStore_Users_Call
func (*MockAuthStore_Users_Call) Run ¶
func (_c *MockAuthStore_Users_Call) Run(run func(ctx context.Context)) *MockAuthStore_Users_Call
func (*MockAuthStore_Users_Call) RunAndReturn ¶
func (_c *MockAuthStore_Users_Call) RunAndReturn(run func(ctx context.Context) ([]storage.User, error)) *MockAuthStore_Users_Call
type MockCollectorStore ¶
MockCollectorStore is an autogenerated mock type for the CollectorStore type
func NewMockCollectorStore ¶
func NewMockCollectorStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockCollectorStore
NewMockCollectorStore creates a new instance of MockCollectorStore. 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 (*MockCollectorStore) AddStatus ¶
func (_mock *MockCollectorStore) AddStatus(ctx context.Context, events []storage.StatusEvent) error
AddStatus provides a mock function for the type MockCollectorStore
func (*MockCollectorStore) CounterStates ¶
func (_mock *MockCollectorStore) CounterStates(ctx context.Context, ids []int64) (map[int64]storage.CounterState, error)
CounterStates provides a mock function for the type MockCollectorStore
func (*MockCollectorStore) EXPECT ¶
func (_m *MockCollectorStore) EXPECT() *MockCollectorStore_Expecter
func (*MockCollectorStore) EnsureSeries ¶
func (_mock *MockCollectorStore) EnsureSeries(ctx context.Context, slot int64, defs []storage.SeriesDef) (map[storage.SeriesKey]int64, error)
EnsureSeries provides a mock function for the type MockCollectorStore
func (*MockCollectorStore) LastStatus ¶
func (_mock *MockCollectorStore) LastStatus(ctx context.Context, device string) (map[string]storage.StatusEvent, error)
LastStatus provides a mock function for the type MockCollectorStore
type MockCollectorStore_AddStatus_Call ¶
MockCollectorStore_AddStatus_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AddStatus'
func (*MockCollectorStore_AddStatus_Call) Return ¶
func (_c *MockCollectorStore_AddStatus_Call) Return(err error) *MockCollectorStore_AddStatus_Call
func (*MockCollectorStore_AddStatus_Call) Run ¶
func (_c *MockCollectorStore_AddStatus_Call) Run(run func(ctx context.Context, events []storage.StatusEvent)) *MockCollectorStore_AddStatus_Call
func (*MockCollectorStore_AddStatus_Call) RunAndReturn ¶
func (_c *MockCollectorStore_AddStatus_Call) RunAndReturn(run func(ctx context.Context, events []storage.StatusEvent) error) *MockCollectorStore_AddStatus_Call
type MockCollectorStore_CounterStates_Call ¶
MockCollectorStore_CounterStates_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CounterStates'
func (*MockCollectorStore_CounterStates_Call) Return ¶
func (_c *MockCollectorStore_CounterStates_Call) Return(int64ToCounterState map[int64]storage.CounterState, err error) *MockCollectorStore_CounterStates_Call
func (*MockCollectorStore_CounterStates_Call) Run ¶
func (_c *MockCollectorStore_CounterStates_Call) Run(run func(ctx context.Context, ids []int64)) *MockCollectorStore_CounterStates_Call
func (*MockCollectorStore_CounterStates_Call) RunAndReturn ¶
func (_c *MockCollectorStore_CounterStates_Call) RunAndReturn(run func(ctx context.Context, ids []int64) (map[int64]storage.CounterState, error)) *MockCollectorStore_CounterStates_Call
type MockCollectorStore_EnsureSeries_Call ¶
MockCollectorStore_EnsureSeries_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'EnsureSeries'
func (*MockCollectorStore_EnsureSeries_Call) Return ¶
func (_c *MockCollectorStore_EnsureSeries_Call) Return(seriesKeyToInt64 map[storage.SeriesKey]int64, err error) *MockCollectorStore_EnsureSeries_Call
func (*MockCollectorStore_EnsureSeries_Call) Run ¶
func (_c *MockCollectorStore_EnsureSeries_Call) Run(run func(ctx context.Context, slot int64, defs []storage.SeriesDef)) *MockCollectorStore_EnsureSeries_Call
func (*MockCollectorStore_EnsureSeries_Call) RunAndReturn ¶
type MockCollectorStore_Expecter ¶
type MockCollectorStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockCollectorStore_Expecter) AddStatus ¶
func (_e *MockCollectorStore_Expecter) AddStatus(ctx any, events any) *MockCollectorStore_AddStatus_Call
AddStatus is a helper method to define mock.On call
- ctx context.Context
- events []storage.StatusEvent
func (*MockCollectorStore_Expecter) CounterStates ¶
func (_e *MockCollectorStore_Expecter) CounterStates(ctx any, ids any) *MockCollectorStore_CounterStates_Call
CounterStates is a helper method to define mock.On call
- ctx context.Context
- ids []int64
func (*MockCollectorStore_Expecter) EnsureSeries ¶
func (_e *MockCollectorStore_Expecter) EnsureSeries(ctx any, slot any, defs any) *MockCollectorStore_EnsureSeries_Call
EnsureSeries is a helper method to define mock.On call
- ctx context.Context
- slot int64
- defs []storage.SeriesDef
func (*MockCollectorStore_Expecter) Flush ¶
func (_e *MockCollectorStore_Expecter) Flush(ctx any, b any) *MockCollectorStore_Flush_Call
Flush is a helper method to define mock.On call
- ctx context.Context
- b storage.Batch
func (*MockCollectorStore_Expecter) LastStatus ¶
func (_e *MockCollectorStore_Expecter) LastStatus(ctx any, device any) *MockCollectorStore_LastStatus_Call
LastStatus is a helper method to define mock.On call
- ctx context.Context
- device string
type MockCollectorStore_Flush_Call ¶
MockCollectorStore_Flush_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Flush'
func (*MockCollectorStore_Flush_Call) Return ¶
func (_c *MockCollectorStore_Flush_Call) Return(err error) *MockCollectorStore_Flush_Call
func (*MockCollectorStore_Flush_Call) Run ¶
func (_c *MockCollectorStore_Flush_Call) Run(run func(ctx context.Context, b storage.Batch)) *MockCollectorStore_Flush_Call
func (*MockCollectorStore_Flush_Call) RunAndReturn ¶
func (_c *MockCollectorStore_Flush_Call) RunAndReturn(run func(ctx context.Context, b storage.Batch) error) *MockCollectorStore_Flush_Call
type MockCollectorStore_LastStatus_Call ¶
MockCollectorStore_LastStatus_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LastStatus'
func (*MockCollectorStore_LastStatus_Call) Return ¶
func (_c *MockCollectorStore_LastStatus_Call) Return(stringToStatusEvent map[string]storage.StatusEvent, err error) *MockCollectorStore_LastStatus_Call
func (*MockCollectorStore_LastStatus_Call) Run ¶
func (_c *MockCollectorStore_LastStatus_Call) Run(run func(ctx context.Context, device string)) *MockCollectorStore_LastStatus_Call
func (*MockCollectorStore_LastStatus_Call) RunAndReturn ¶
func (_c *MockCollectorStore_LastStatus_Call) RunAndReturn(run func(ctx context.Context, device string) (map[string]storage.StatusEvent, error)) *MockCollectorStore_LastStatus_Call
type MockConfigStore ¶
MockConfigStore is an autogenerated mock type for the ConfigStore type
func NewMockConfigStore ¶
func NewMockConfigStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockConfigStore
NewMockConfigStore creates a new instance of MockConfigStore. 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 (*MockConfigStore) ApplyConfig ¶
func (_mock *MockConfigStore) ApplyConfig(ctx context.Context, c storage.ConfigChange) (int64, error)
ApplyConfig provides a mock function for the type MockConfigStore
func (*MockConfigStore) ConfigState ¶
func (_mock *MockConfigStore) ConfigState(ctx context.Context) (storage.ConfigState, error)
ConfigState provides a mock function for the type MockConfigStore
func (*MockConfigStore) EXPECT ¶
func (_m *MockConfigStore) EXPECT() *MockConfigStore_Expecter
type MockConfigStore_ApplyConfig_Call ¶
MockConfigStore_ApplyConfig_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ApplyConfig'
func (*MockConfigStore_ApplyConfig_Call) Return ¶
func (_c *MockConfigStore_ApplyConfig_Call) Return(n int64, err error) *MockConfigStore_ApplyConfig_Call
func (*MockConfigStore_ApplyConfig_Call) Run ¶
func (_c *MockConfigStore_ApplyConfig_Call) Run(run func(ctx context.Context, c storage.ConfigChange)) *MockConfigStore_ApplyConfig_Call
func (*MockConfigStore_ApplyConfig_Call) RunAndReturn ¶
func (_c *MockConfigStore_ApplyConfig_Call) RunAndReturn(run func(ctx context.Context, c storage.ConfigChange) (int64, error)) *MockConfigStore_ApplyConfig_Call
type MockConfigStore_ConfigState_Call ¶
MockConfigStore_ConfigState_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigState'
func (*MockConfigStore_ConfigState_Call) Return ¶
func (_c *MockConfigStore_ConfigState_Call) Return(configState storage.ConfigState, err error) *MockConfigStore_ConfigState_Call
func (*MockConfigStore_ConfigState_Call) Run ¶
func (_c *MockConfigStore_ConfigState_Call) Run(run func(ctx context.Context)) *MockConfigStore_ConfigState_Call
func (*MockConfigStore_ConfigState_Call) RunAndReturn ¶
func (_c *MockConfigStore_ConfigState_Call) RunAndReturn(run func(ctx context.Context) (storage.ConfigState, error)) *MockConfigStore_ConfigState_Call
type MockConfigStore_Expecter ¶
type MockConfigStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockConfigStore_Expecter) ApplyConfig ¶
func (_e *MockConfigStore_Expecter) ApplyConfig(ctx any, c any) *MockConfigStore_ApplyConfig_Call
ApplyConfig is a helper method to define mock.On call
- ctx context.Context
- c storage.ConfigChange
func (*MockConfigStore_Expecter) ConfigState ¶
func (_e *MockConfigStore_Expecter) ConfigState(ctx any) *MockConfigStore_ConfigState_Call
ConfigState is a helper method to define mock.On call
- ctx context.Context
type MockDeriveStore ¶
MockDeriveStore is an autogenerated mock type for the DeriveStore type
func NewMockDeriveStore ¶
func NewMockDeriveStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockDeriveStore
NewMockDeriveStore creates a new instance of MockDeriveStore. 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 (*MockDeriveStore) CacheGen ¶
func (_mock *MockDeriveStore) CacheGen() int64
CacheGen provides a mock function for the type MockDeriveStore
func (*MockDeriveStore) CacheGet ¶
func (_mock *MockDeriveStore) CacheGet(ctx context.Context, keys []string, configRev int64) (map[string]string, error)
CacheGet provides a mock function for the type MockDeriveStore
func (*MockDeriveStore) CachePut ¶
func (_mock *MockDeriveStore) CachePut(ctx context.Context, configRev int64, gen int64, entries map[string]string) error
CachePut provides a mock function for the type MockDeriveStore
func (*MockDeriveStore) EXPECT ¶
func (_m *MockDeriveStore) EXPECT() *MockDeriveStore_Expecter
type MockDeriveStore_CacheGen_Call ¶
MockDeriveStore_CacheGen_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CacheGen'
func (*MockDeriveStore_CacheGen_Call) Return ¶
func (_c *MockDeriveStore_CacheGen_Call) Return(n int64) *MockDeriveStore_CacheGen_Call
func (*MockDeriveStore_CacheGen_Call) Run ¶
func (_c *MockDeriveStore_CacheGen_Call) Run(run func()) *MockDeriveStore_CacheGen_Call
func (*MockDeriveStore_CacheGen_Call) RunAndReturn ¶
func (_c *MockDeriveStore_CacheGen_Call) RunAndReturn(run func() int64) *MockDeriveStore_CacheGen_Call
type MockDeriveStore_CacheGet_Call ¶
MockDeriveStore_CacheGet_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CacheGet'
func (*MockDeriveStore_CacheGet_Call) Return ¶
func (_c *MockDeriveStore_CacheGet_Call) Return(stringToString map[string]string, err error) *MockDeriveStore_CacheGet_Call
func (*MockDeriveStore_CacheGet_Call) Run ¶
func (_c *MockDeriveStore_CacheGet_Call) Run(run func(ctx context.Context, keys []string, configRev int64)) *MockDeriveStore_CacheGet_Call
func (*MockDeriveStore_CacheGet_Call) RunAndReturn ¶
func (_c *MockDeriveStore_CacheGet_Call) RunAndReturn(run func(ctx context.Context, keys []string, configRev int64) (map[string]string, error)) *MockDeriveStore_CacheGet_Call
type MockDeriveStore_CachePut_Call ¶
MockDeriveStore_CachePut_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CachePut'
func (*MockDeriveStore_CachePut_Call) Return ¶
func (_c *MockDeriveStore_CachePut_Call) Return(err error) *MockDeriveStore_CachePut_Call
func (*MockDeriveStore_CachePut_Call) Run ¶
func (_c *MockDeriveStore_CachePut_Call) Run(run func(ctx context.Context, configRev int64, gen int64, entries map[string]string)) *MockDeriveStore_CachePut_Call
func (*MockDeriveStore_CachePut_Call) RunAndReturn ¶
func (_c *MockDeriveStore_CachePut_Call) RunAndReturn(run func(ctx context.Context, configRev int64, gen int64, entries map[string]string) error) *MockDeriveStore_CachePut_Call
type MockDeriveStore_Expecter ¶
type MockDeriveStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockDeriveStore_Expecter) CacheGen ¶
func (_e *MockDeriveStore_Expecter) CacheGen() *MockDeriveStore_CacheGen_Call
CacheGen is a helper method to define mock.On call
func (*MockDeriveStore_Expecter) CacheGet ¶
func (_e *MockDeriveStore_Expecter) CacheGet(ctx any, keys any, configRev any) *MockDeriveStore_CacheGet_Call
CacheGet is a helper method to define mock.On call
- ctx context.Context
- keys []string
- configRev int64
func (*MockDeriveStore_Expecter) CachePut ¶
func (_e *MockDeriveStore_Expecter) CachePut(ctx any, configRev any, gen any, entries any) *MockDeriveStore_CachePut_Call
CachePut is a helper method to define mock.On call
- ctx context.Context
- configRev int64
- gen int64
- entries map[string]string
type MockImportStore ¶
MockImportStore is an autogenerated mock type for the ImportStore type
func NewMockImportStore ¶
func NewMockImportStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockImportStore
NewMockImportStore creates a new instance of MockImportStore. 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 (*MockImportStore) EXPECT ¶
func (_m *MockImportStore) EXPECT() *MockImportStore_Expecter
func (*MockImportStore) Import ¶
func (_mock *MockImportStore) Import(ctx context.Context, b storage.ImportBatch) error
Import provides a mock function for the type MockImportStore
func (*MockImportStore) ImportSource ¶
func (_mock *MockImportStore) ImportSource(ctx context.Context) (string, error)
ImportSource provides a mock function for the type MockImportStore
type MockImportStore_Expecter ¶
type MockImportStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockImportStore_Expecter) FirstSlot ¶
func (_e *MockImportStore_Expecter) FirstSlot(ctx any) *MockImportStore_FirstSlot_Call
FirstSlot is a helper method to define mock.On call
- ctx context.Context
func (*MockImportStore_Expecter) Import ¶
func (_e *MockImportStore_Expecter) Import(ctx any, b any) *MockImportStore_Import_Call
Import is a helper method to define mock.On call
- ctx context.Context
- b storage.ImportBatch
func (*MockImportStore_Expecter) ImportSource ¶
func (_e *MockImportStore_Expecter) ImportSource(ctx any) *MockImportStore_ImportSource_Call
ImportSource is a helper method to define mock.On call
- ctx context.Context
type MockImportStore_FirstSlot_Call ¶
MockImportStore_FirstSlot_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FirstSlot'
func (*MockImportStore_FirstSlot_Call) Return ¶
func (_c *MockImportStore_FirstSlot_Call) Return(slot int64, ok bool, err error) *MockImportStore_FirstSlot_Call
func (*MockImportStore_FirstSlot_Call) Run ¶
func (_c *MockImportStore_FirstSlot_Call) Run(run func(ctx context.Context)) *MockImportStore_FirstSlot_Call
func (*MockImportStore_FirstSlot_Call) RunAndReturn ¶
func (_c *MockImportStore_FirstSlot_Call) RunAndReturn(run func(ctx context.Context) (int64, bool, error)) *MockImportStore_FirstSlot_Call
type MockImportStore_ImportSource_Call ¶
MockImportStore_ImportSource_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ImportSource'
func (*MockImportStore_ImportSource_Call) Return ¶
func (_c *MockImportStore_ImportSource_Call) Return(s string, err error) *MockImportStore_ImportSource_Call
func (*MockImportStore_ImportSource_Call) Run ¶
func (_c *MockImportStore_ImportSource_Call) Run(run func(ctx context.Context)) *MockImportStore_ImportSource_Call
func (*MockImportStore_ImportSource_Call) RunAndReturn ¶
func (_c *MockImportStore_ImportSource_Call) RunAndReturn(run func(ctx context.Context) (string, error)) *MockImportStore_ImportSource_Call
type MockImportStore_Import_Call ¶
MockImportStore_Import_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Import'
func (*MockImportStore_Import_Call) Return ¶
func (_c *MockImportStore_Import_Call) Return(err error) *MockImportStore_Import_Call
func (*MockImportStore_Import_Call) Run ¶
func (_c *MockImportStore_Import_Call) Run(run func(ctx context.Context, b storage.ImportBatch)) *MockImportStore_Import_Call
func (*MockImportStore_Import_Call) RunAndReturn ¶
func (_c *MockImportStore_Import_Call) RunAndReturn(run func(ctx context.Context, b storage.ImportBatch) error) *MockImportStore_Import_Call
type MockReadStore ¶
MockReadStore is an autogenerated mock type for the ReadStore type
func NewMockReadStore ¶
func NewMockReadStore(t interface {
mock.TestingT
Cleanup(func())
}) *MockReadStore
NewMockReadStore creates a new instance of MockReadStore. 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 (*MockReadStore) EXPECT ¶
func (_m *MockReadStore) EXPECT() *MockReadStore_Expecter
func (*MockReadStore) EnergyBuckets ¶
func (_mock *MockReadStore) EnergyBuckets(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.EnergyBucket, error)
EnergyBuckets provides a mock function for the type MockReadStore
func (*MockReadStore) GaugeBuckets ¶
func (_mock *MockReadStore) GaugeBuckets(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.GaugeBucket, error)
GaugeBuckets provides a mock function for the type MockReadStore
func (*MockReadStore) StatusEvents ¶
func (_mock *MockReadStore) StatusEvents(ctx context.Context, device string, from int64, to int64, limit int) ([]storage.StatusEvent, error)
StatusEvents provides a mock function for the type MockReadStore
type MockReadStore_Carry_Call ¶
MockReadStore_Carry_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Carry'
func (*MockReadStore_Carry_Call) Return ¶
func (_c *MockReadStore_Carry_Call) Return(int64ToFloat64 map[int64]float64, err error) *MockReadStore_Carry_Call
func (*MockReadStore_Carry_Call) Run ¶
func (_c *MockReadStore_Carry_Call) Run(run func(ctx context.Context, ids []int64)) *MockReadStore_Carry_Call
func (*MockReadStore_Carry_Call) RunAndReturn ¶
func (_c *MockReadStore_Carry_Call) RunAndReturn(run func(ctx context.Context, ids []int64) (map[int64]float64, error)) *MockReadStore_Carry_Call
type MockReadStore_EnergyBuckets_Call ¶
MockReadStore_EnergyBuckets_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'EnergyBuckets'
func (*MockReadStore_EnergyBuckets_Call) Return ¶
func (_c *MockReadStore_EnergyBuckets_Call) Return(energyBuckets []storage.EnergyBucket, err error) *MockReadStore_EnergyBuckets_Call
func (*MockReadStore_EnergyBuckets_Call) Run ¶
func (_c *MockReadStore_EnergyBuckets_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_EnergyBuckets_Call
func (*MockReadStore_EnergyBuckets_Call) RunAndReturn ¶
func (_c *MockReadStore_EnergyBuckets_Call) RunAndReturn(run func(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.EnergyBucket, error)) *MockReadStore_EnergyBuckets_Call
type MockReadStore_Expecter ¶
type MockReadStore_Expecter struct {
// contains filtered or unexported fields
}
func (*MockReadStore_Expecter) Carry ¶
func (_e *MockReadStore_Expecter) Carry(ctx any, ids any) *MockReadStore_Carry_Call
Carry is a helper method to define mock.On call
- ctx context.Context
- ids []int64
func (*MockReadStore_Expecter) EnergyBuckets ¶
func (_e *MockReadStore_Expecter) EnergyBuckets(ctx any, seriesID any, from any, to any) *MockReadStore_EnergyBuckets_Call
EnergyBuckets is a helper method to define mock.On call
- ctx context.Context
- seriesID int64
- from int64
- to int64
func (*MockReadStore_Expecter) FirstSlot ¶
func (_e *MockReadStore_Expecter) FirstSlot(ctx any) *MockReadStore_FirstSlot_Call
FirstSlot is a helper method to define mock.On call
- ctx context.Context
func (*MockReadStore_Expecter) GaugeBuckets ¶
func (_e *MockReadStore_Expecter) GaugeBuckets(ctx any, seriesID any, from any, to any) *MockReadStore_GaugeBuckets_Call
GaugeBuckets is a helper method to define mock.On call
- ctx context.Context
- seriesID int64
- from int64
- to int64
func (*MockReadStore_Expecter) SeriesID ¶
func (_e *MockReadStore_Expecter) SeriesID(ctx any, key any) *MockReadStore_SeriesID_Call
SeriesID is a helper method to define mock.On call
- ctx context.Context
- key storage.SeriesKey
func (*MockReadStore_Expecter) StatusEvents ¶
func (_e *MockReadStore_Expecter) StatusEvents(ctx any, device any, from any, to any, limit any) *MockReadStore_StatusEvents_Call
StatusEvents is a helper method to define mock.On call
- ctx context.Context
- device string
- from int64
- to int64
- limit int
func (*MockReadStore_Expecter) SumEnergy ¶
func (_e *MockReadStore_Expecter) SumEnergy(ctx any, seriesID any, from any, to any) *MockReadStore_SumEnergy_Call
SumEnergy is a helper method to define mock.On call
- ctx context.Context
- seriesID int64
- from int64
- to int64
func (*MockReadStore_Expecter) SumEnergyMany ¶
func (_e *MockReadStore_Expecter) SumEnergyMany(ctx any, ids any, from any, to any, closedBefore any) *MockReadStore_SumEnergyMany_Call
SumEnergyMany is a helper method to define mock.On call
- ctx context.Context
- ids []int64
- from int64
- to int64
- closedBefore int64
type MockReadStore_FirstSlot_Call ¶
MockReadStore_FirstSlot_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FirstSlot'
func (*MockReadStore_FirstSlot_Call) Return ¶
func (_c *MockReadStore_FirstSlot_Call) Return(slot int64, ok bool, err error) *MockReadStore_FirstSlot_Call
func (*MockReadStore_FirstSlot_Call) Run ¶
func (_c *MockReadStore_FirstSlot_Call) Run(run func(ctx context.Context)) *MockReadStore_FirstSlot_Call
func (*MockReadStore_FirstSlot_Call) RunAndReturn ¶
func (_c *MockReadStore_FirstSlot_Call) RunAndReturn(run func(ctx context.Context) (int64, bool, error)) *MockReadStore_FirstSlot_Call
type MockReadStore_GaugeBuckets_Call ¶
MockReadStore_GaugeBuckets_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GaugeBuckets'
func (*MockReadStore_GaugeBuckets_Call) Return ¶
func (_c *MockReadStore_GaugeBuckets_Call) Return(gaugeBuckets []storage.GaugeBucket, err error) *MockReadStore_GaugeBuckets_Call
func (*MockReadStore_GaugeBuckets_Call) Run ¶
func (_c *MockReadStore_GaugeBuckets_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_GaugeBuckets_Call
func (*MockReadStore_GaugeBuckets_Call) RunAndReturn ¶
func (_c *MockReadStore_GaugeBuckets_Call) RunAndReturn(run func(ctx context.Context, seriesID int64, from int64, to int64) ([]storage.GaugeBucket, error)) *MockReadStore_GaugeBuckets_Call
type MockReadStore_SeriesID_Call ¶
MockReadStore_SeriesID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SeriesID'
func (*MockReadStore_SeriesID_Call) Return ¶
func (_c *MockReadStore_SeriesID_Call) Return(n int64, err error) *MockReadStore_SeriesID_Call
func (*MockReadStore_SeriesID_Call) Run ¶
func (_c *MockReadStore_SeriesID_Call) Run(run func(ctx context.Context, key storage.SeriesKey)) *MockReadStore_SeriesID_Call
func (*MockReadStore_SeriesID_Call) RunAndReturn ¶
func (_c *MockReadStore_SeriesID_Call) RunAndReturn(run func(ctx context.Context, key storage.SeriesKey) (int64, error)) *MockReadStore_SeriesID_Call
type MockReadStore_StatusEvents_Call ¶
MockReadStore_StatusEvents_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'StatusEvents'
func (*MockReadStore_StatusEvents_Call) Return ¶
func (_c *MockReadStore_StatusEvents_Call) Return(statusEvents []storage.StatusEvent, err error) *MockReadStore_StatusEvents_Call
func (*MockReadStore_StatusEvents_Call) Run ¶
func (_c *MockReadStore_StatusEvents_Call) Run(run func(ctx context.Context, device string, from int64, to int64, limit int)) *MockReadStore_StatusEvents_Call
func (*MockReadStore_StatusEvents_Call) RunAndReturn ¶
func (_c *MockReadStore_StatusEvents_Call) RunAndReturn(run func(ctx context.Context, device string, from int64, to int64, limit int) ([]storage.StatusEvent, error)) *MockReadStore_StatusEvents_Call
type MockReadStore_SumEnergyMany_Call ¶
MockReadStore_SumEnergyMany_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SumEnergyMany'
func (*MockReadStore_SumEnergyMany_Call) Return ¶
func (_c *MockReadStore_SumEnergyMany_Call) Return(int64ToEnergySum map[int64]storage.EnergySum, err error) *MockReadStore_SumEnergyMany_Call
func (*MockReadStore_SumEnergyMany_Call) Run ¶
func (_c *MockReadStore_SumEnergyMany_Call) Run(run func(ctx context.Context, ids []int64, from int64, to int64, closedBefore int64)) *MockReadStore_SumEnergyMany_Call
func (*MockReadStore_SumEnergyMany_Call) RunAndReturn ¶
type MockReadStore_SumEnergy_Call ¶
MockReadStore_SumEnergy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SumEnergy'
func (*MockReadStore_SumEnergy_Call) Return ¶
func (_c *MockReadStore_SumEnergy_Call) Return(energyTotal storage.EnergyTotal, err error) *MockReadStore_SumEnergy_Call
func (*MockReadStore_SumEnergy_Call) Run ¶
func (_c *MockReadStore_SumEnergy_Call) Run(run func(ctx context.Context, seriesID int64, from int64, to int64)) *MockReadStore_SumEnergy_Call
func (*MockReadStore_SumEnergy_Call) RunAndReturn ¶
func (_c *MockReadStore_SumEnergy_Call) RunAndReturn(run func(ctx context.Context, seriesID int64, from int64, to int64) (storage.EnergyTotal, error)) *MockReadStore_SumEnergy_Call