MCPcopy Create free account
hub / github.com/TheThingsNetwork/lorawan-stack / MockKeyRegistry

Struct MockKeyRegistry

pkg/joinserver/joinserver_internal_test.go:120–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

118}
119
120type MockKeyRegistry struct {
121 GetByIDFunc func(context.Context, types.EUI64, types.EUI64, []byte, []string) (*ttnpb.SessionKeys, error)
122 SetByIDFunc func(
123 context.Context,
124 types.EUI64,
125 types.EUI64,
126 []byte,
127 []string,
128 func(*ttnpb.SessionKeys) (*ttnpb.SessionKeys, []string, error),
129 ) (*ttnpb.SessionKeys, error)
130 DeleteFunc func(context.Context, types.EUI64, types.EUI64) error
131 BatchDeleteFunc func(context.Context, []*ttnpb.EndDeviceIdentifiers) error
132}
133
134// GetByID calls GetByIDFunc if set and panics otherwise.
135func (m MockKeyRegistry) GetByID(ctx context.Context, joinEUI, devEUI types.EUI64, id []byte, paths []string) (*ttnpb.SessionKeys, error) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected