Documentation ¶
Overview ¶
Package mocks contains mocks for testing purposes.
Index ¶
- type ConfigReader
- type ConfigRepository
- func (_m *ConfigRepository) ChangeState(ctx context.Context, domainID string, id string, state bootstrap.State) error
- func (_m *ConfigRepository) ConnectThing(ctx context.Context, channelID string, thingID string) error
- func (_m *ConfigRepository) DisconnectThing(ctx context.Context, channelID string, thingID string) error
- func (_m *ConfigRepository) ListExisting(ctx context.Context, domainID string, ids []string) ([]bootstrap.Channel, error)
- func (_m *ConfigRepository) Remove(ctx context.Context, domainID string, id string) error
- func (_m *ConfigRepository) RemoveChannel(ctx context.Context, id string) error
- func (_m *ConfigRepository) RemoveThing(ctx context.Context, id string) error
- func (_m *ConfigRepository) RetrieveAll(ctx context.Context, domainID string, thingIDs []string, ...) bootstrap.ConfigsPage
- func (_m *ConfigRepository) RetrieveByExternalID(ctx context.Context, externalID string) (bootstrap.Config, error)
- func (_m *ConfigRepository) RetrieveByID(ctx context.Context, domainID string, id string) (bootstrap.Config, error)
- func (_m *ConfigRepository) Save(ctx context.Context, cfg bootstrap.Config, chsConnIDs []string) (string, error)
- func (_m *ConfigRepository) Update(ctx context.Context, cfg bootstrap.Config) error
- func (_m *ConfigRepository) UpdateCert(ctx context.Context, domainID string, thingID string, clientCert string, ...) (bootstrap.Config, error)
- func (_m *ConfigRepository) UpdateChannel(ctx context.Context, c bootstrap.Channel) error
- func (_m *ConfigRepository) UpdateConnections(ctx context.Context, domainID string, id string, channels []bootstrap.Channel, ...) error
- type Service
- func (_m *Service) Add(ctx context.Context, session authn.Session, token string, cfg bootstrap.Config) (bootstrap.Config, error)
- func (_m *Service) Bootstrap(ctx context.Context, externalKey string, externalID string, secure bool) (bootstrap.Config, error)
- func (_m *Service) ChangeState(ctx context.Context, session authn.Session, token string, id string, ...) error
- func (_m *Service) ConnectThingHandler(ctx context.Context, channelID string, ThingID string) error
- func (_m *Service) DisconnectThingHandler(ctx context.Context, channelID string, ThingID string) error
- func (_m *Service) List(ctx context.Context, session authn.Session, filter bootstrap.Filter, ...) (bootstrap.ConfigsPage, error)
- func (_m *Service) Remove(ctx context.Context, session authn.Session, id string) error
- func (_m *Service) RemoveChannelHandler(ctx context.Context, id string) error
- func (_m *Service) RemoveConfigHandler(ctx context.Context, id string) error
- func (_m *Service) Update(ctx context.Context, session authn.Session, cfg bootstrap.Config) error
- func (_m *Service) UpdateCert(ctx context.Context, session authn.Session, thingID string, clientCert string, ...) (bootstrap.Config, error)
- func (_m *Service) UpdateChannelHandler(ctx context.Context, channel bootstrap.Channel) error
- func (_m *Service) UpdateConnections(ctx context.Context, session authn.Session, token string, id string, ...) error
- func (_m *Service) View(ctx context.Context, session authn.Session, id string) (bootstrap.Config, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigReader ¶ added in v0.15.0
ConfigReader is an autogenerated mock type for the ConfigReader type
func NewConfigReader ¶ added in v0.15.0
func NewConfigReader(t interface { mock.TestingT Cleanup(func()) }) *ConfigReader
NewConfigReader creates a new instance of ConfigReader. 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 (*ConfigReader) ReadConfig ¶ added in v0.15.0
func (_m *ConfigReader) ReadConfig(_a0 bootstrap.Config, _a1 bool) (interface{}, error)
ReadConfig provides a mock function with given fields: _a0, _a1
type ConfigRepository ¶ added in v0.15.0
ConfigRepository is an autogenerated mock type for the ConfigRepository type
func NewConfigRepository ¶ added in v0.15.0
func NewConfigRepository(t interface { mock.TestingT Cleanup(func()) }) *ConfigRepository
NewConfigRepository creates a new instance of ConfigRepository. 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 (*ConfigRepository) ChangeState ¶ added in v0.15.0
func (_m *ConfigRepository) ChangeState(ctx context.Context, domainID string, id string, state bootstrap.State) error
ChangeState provides a mock function with given fields: ctx, domainID, id, state
func (*ConfigRepository) ConnectThing ¶ added in v0.15.0
func (_m *ConfigRepository) ConnectThing(ctx context.Context, channelID string, thingID string) error
ConnectThing provides a mock function with given fields: ctx, channelID, thingID
func (*ConfigRepository) DisconnectThing ¶ added in v0.15.0
func (_m *ConfigRepository) DisconnectThing(ctx context.Context, channelID string, thingID string) error
DisconnectThing provides a mock function with given fields: ctx, channelID, thingID
func (*ConfigRepository) ListExisting ¶ added in v0.15.0
func (_m *ConfigRepository) ListExisting(ctx context.Context, domainID string, ids []string) ([]bootstrap.Channel, error)
ListExisting provides a mock function with given fields: ctx, domainID, ids
func (*ConfigRepository) Remove ¶ added in v0.15.0
Remove provides a mock function with given fields: ctx, domainID, id
func (*ConfigRepository) RemoveChannel ¶ added in v0.15.0
func (_m *ConfigRepository) RemoveChannel(ctx context.Context, id string) error
RemoveChannel provides a mock function with given fields: ctx, id
func (*ConfigRepository) RemoveThing ¶ added in v0.15.0
func (_m *ConfigRepository) RemoveThing(ctx context.Context, id string) error
RemoveThing provides a mock function with given fields: ctx, id
func (*ConfigRepository) RetrieveAll ¶ added in v0.15.0
func (_m *ConfigRepository) RetrieveAll(ctx context.Context, domainID string, thingIDs []string, filter bootstrap.Filter, offset uint64, limit uint64) bootstrap.ConfigsPage
RetrieveAll provides a mock function with given fields: ctx, domainID, thingIDs, filter, offset, limit
func (*ConfigRepository) RetrieveByExternalID ¶ added in v0.15.0
func (_m *ConfigRepository) RetrieveByExternalID(ctx context.Context, externalID string) (bootstrap.Config, error)
RetrieveByExternalID provides a mock function with given fields: ctx, externalID
func (*ConfigRepository) RetrieveByID ¶ added in v0.15.0
func (_m *ConfigRepository) RetrieveByID(ctx context.Context, domainID string, id string) (bootstrap.Config, error)
RetrieveByID provides a mock function with given fields: ctx, domainID, id
func (*ConfigRepository) Save ¶ added in v0.15.0
func (_m *ConfigRepository) Save(ctx context.Context, cfg bootstrap.Config, chsConnIDs []string) (string, error)
Save provides a mock function with given fields: ctx, cfg, chsConnIDs
func (*ConfigRepository) Update ¶ added in v0.15.0
Update provides a mock function with given fields: ctx, cfg
func (*ConfigRepository) UpdateCert ¶ added in v0.15.0
func (_m *ConfigRepository) UpdateCert(ctx context.Context, domainID string, thingID string, clientCert string, clientKey string, caCert string) (bootstrap.Config, error)
UpdateCert provides a mock function with given fields: ctx, domainID, thingID, clientCert, clientKey, caCert
func (*ConfigRepository) UpdateChannel ¶ added in v0.15.0
UpdateChannel provides a mock function with given fields: ctx, c
func (*ConfigRepository) UpdateConnections ¶ added in v0.15.0
func (_m *ConfigRepository) UpdateConnections(ctx context.Context, domainID string, id string, channels []bootstrap.Channel, connections []string) error
UpdateConnections provides a mock function with given fields: ctx, domainID, id, channels, connections
type Service ¶ added in v0.15.0
Service is an autogenerated mock type for the Service type
func NewService ¶ added in v0.15.0
NewService creates a new instance of Service. 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 (*Service) Add ¶ added in v0.15.0
func (_m *Service) Add(ctx context.Context, session authn.Session, token string, cfg bootstrap.Config) (bootstrap.Config, error)
Add provides a mock function with given fields: ctx, session, token, cfg
func (*Service) Bootstrap ¶ added in v0.15.0
func (_m *Service) Bootstrap(ctx context.Context, externalKey string, externalID string, secure bool) (bootstrap.Config, error)
Bootstrap provides a mock function with given fields: ctx, externalKey, externalID, secure
func (*Service) ChangeState ¶ added in v0.15.0
func (_m *Service) ChangeState(ctx context.Context, session authn.Session, token string, id string, state bootstrap.State) error
ChangeState provides a mock function with given fields: ctx, session, token, id, state
func (*Service) ConnectThingHandler ¶ added in v0.15.0
ConnectThingHandler provides a mock function with given fields: ctx, channelID, ThingID
func (*Service) DisconnectThingHandler ¶ added in v0.15.0
func (_m *Service) DisconnectThingHandler(ctx context.Context, channelID string, ThingID string) error
DisconnectThingHandler provides a mock function with given fields: ctx, channelID, ThingID
func (*Service) List ¶ added in v0.15.0
func (_m *Service) List(ctx context.Context, session authn.Session, filter bootstrap.Filter, offset uint64, limit uint64) (bootstrap.ConfigsPage, error)
List provides a mock function with given fields: ctx, session, filter, offset, limit
func (*Service) Remove ¶ added in v0.15.0
Remove provides a mock function with given fields: ctx, session, id
func (*Service) RemoveChannelHandler ¶ added in v0.15.0
RemoveChannelHandler provides a mock function with given fields: ctx, id
func (*Service) RemoveConfigHandler ¶ added in v0.15.0
RemoveConfigHandler provides a mock function with given fields: ctx, id
func (*Service) Update ¶ added in v0.15.0
Update provides a mock function with given fields: ctx, session, cfg
func (*Service) UpdateCert ¶ added in v0.15.0
func (_m *Service) UpdateCert(ctx context.Context, session authn.Session, thingID string, clientCert string, clientKey string, caCert string) (bootstrap.Config, error)
UpdateCert provides a mock function with given fields: ctx, session, thingID, clientCert, clientKey, caCert
func (*Service) UpdateChannelHandler ¶ added in v0.15.0
UpdateChannelHandler provides a mock function with given fields: ctx, channel