Documentation ¶
Index ¶
- type DON
- type DON_Expecter
- type DON_SendToNode_Call
- func (_c *DON_SendToNode_Call) Return(_a0 error) *DON_SendToNode_Call
- func (_c *DON_SendToNode_Call) Run(run func(ctx context.Context, nodeAddress string, msg *api.Message)) *DON_SendToNode_Call
- func (_c *DON_SendToNode_Call) RunAndReturn(run func(context.Context, string, *api.Message) error) *DON_SendToNode_Call
- type Handler
- func (_m *Handler) Close() error
- func (_m *Handler) EXPECT() *Handler_Expecter
- func (_m *Handler) HandleNodeMessage(ctx context.Context, msg *api.Message, nodeAddr string) error
- func (_m *Handler) HandleUserMessage(ctx context.Context, msg *api.Message, ...) error
- func (_m *Handler) Start(_a0 context.Context) error
- type Handler_Close_Call
- type Handler_Expecter
- func (_e *Handler_Expecter) Close() *Handler_Close_Call
- func (_e *Handler_Expecter) HandleNodeMessage(ctx interface{}, msg interface{}, nodeAddr interface{}) *Handler_HandleNodeMessage_Call
- func (_e *Handler_Expecter) HandleUserMessage(ctx interface{}, msg interface{}, callbackCh interface{}) *Handler_HandleUserMessage_Call
- func (_e *Handler_Expecter) Start(_a0 interface{}) *Handler_Start_Call
- type Handler_HandleNodeMessage_Call
- func (_c *Handler_HandleNodeMessage_Call) Return(_a0 error) *Handler_HandleNodeMessage_Call
- func (_c *Handler_HandleNodeMessage_Call) Run(run func(ctx context.Context, msg *api.Message, nodeAddr string)) *Handler_HandleNodeMessage_Call
- func (_c *Handler_HandleNodeMessage_Call) RunAndReturn(run func(context.Context, *api.Message, string) error) *Handler_HandleNodeMessage_Call
- type Handler_HandleUserMessage_Call
- func (_c *Handler_HandleUserMessage_Call) Return(_a0 error) *Handler_HandleUserMessage_Call
- func (_c *Handler_HandleUserMessage_Call) Run(run func(ctx context.Context, msg *api.Message, ...)) *Handler_HandleUserMessage_Call
- func (_c *Handler_HandleUserMessage_Call) RunAndReturn(...) *Handler_HandleUserMessage_Call
- type Handler_Start_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DON ¶ added in v2.4.0
DON is an autogenerated mock type for the DON type
func NewDON ¶ added in v2.4.0
NewDON creates a new instance of DON. 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 (*DON) EXPECT ¶ added in v2.15.0
func (_m *DON) EXPECT() *DON_Expecter
type DON_Expecter ¶ added in v2.15.0
type DON_Expecter struct {
// contains filtered or unexported fields
}
func (*DON_Expecter) SendToNode ¶ added in v2.15.0
func (_e *DON_Expecter) SendToNode(ctx interface{}, nodeAddress interface{}, msg interface{}) *DON_SendToNode_Call
SendToNode is a helper method to define mock.On call
- ctx context.Context
- nodeAddress string
- msg *api.Message
type DON_SendToNode_Call ¶ added in v2.15.0
DON_SendToNode_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SendToNode'
func (*DON_SendToNode_Call) Return ¶ added in v2.15.0
func (_c *DON_SendToNode_Call) Return(_a0 error) *DON_SendToNode_Call
func (*DON_SendToNode_Call) Run ¶ added in v2.15.0
func (_c *DON_SendToNode_Call) Run(run func(ctx context.Context, nodeAddress string, msg *api.Message)) *DON_SendToNode_Call
func (*DON_SendToNode_Call) RunAndReturn ¶ added in v2.15.0
func (_c *DON_SendToNode_Call) RunAndReturn(run func(context.Context, string, *api.Message) error) *DON_SendToNode_Call
type Handler ¶
Handler is an autogenerated mock type for the Handler type
func NewHandler ¶
NewHandler creates a new instance of Handler. 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 (*Handler) EXPECT ¶ added in v2.15.0
func (_m *Handler) EXPECT() *Handler_Expecter
func (*Handler) HandleNodeMessage ¶
HandleNodeMessage provides a mock function with given fields: ctx, msg, nodeAddr
func (*Handler) HandleUserMessage ¶
func (_m *Handler) HandleUserMessage(ctx context.Context, msg *api.Message, callbackCh chan<- handlers.UserCallbackPayload) error
HandleUserMessage provides a mock function with given fields: ctx, msg, callbackCh
type Handler_Close_Call ¶ added in v2.15.0
Handler_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
func (*Handler_Close_Call) Return ¶ added in v2.15.0
func (_c *Handler_Close_Call) Return(_a0 error) *Handler_Close_Call
func (*Handler_Close_Call) Run ¶ added in v2.15.0
func (_c *Handler_Close_Call) Run(run func()) *Handler_Close_Call
func (*Handler_Close_Call) RunAndReturn ¶ added in v2.15.0
func (_c *Handler_Close_Call) RunAndReturn(run func() error) *Handler_Close_Call
type Handler_Expecter ¶ added in v2.15.0
type Handler_Expecter struct {
// contains filtered or unexported fields
}
func (*Handler_Expecter) Close ¶ added in v2.15.0
func (_e *Handler_Expecter) Close() *Handler_Close_Call
Close is a helper method to define mock.On call
func (*Handler_Expecter) HandleNodeMessage ¶ added in v2.15.0
func (_e *Handler_Expecter) HandleNodeMessage(ctx interface{}, msg interface{}, nodeAddr interface{}) *Handler_HandleNodeMessage_Call
HandleNodeMessage is a helper method to define mock.On call
- ctx context.Context
- msg *api.Message
- nodeAddr string
func (*Handler_Expecter) HandleUserMessage ¶ added in v2.15.0
func (_e *Handler_Expecter) HandleUserMessage(ctx interface{}, msg interface{}, callbackCh interface{}) *Handler_HandleUserMessage_Call
HandleUserMessage is a helper method to define mock.On call
- ctx context.Context
- msg *api.Message
- callbackCh chan<- handlers.UserCallbackPayload
func (*Handler_Expecter) Start ¶ added in v2.15.0
func (_e *Handler_Expecter) Start(_a0 interface{}) *Handler_Start_Call
Start is a helper method to define mock.On call
- _a0 context.Context
type Handler_HandleNodeMessage_Call ¶ added in v2.15.0
Handler_HandleNodeMessage_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HandleNodeMessage'
func (*Handler_HandleNodeMessage_Call) Return ¶ added in v2.15.0
func (_c *Handler_HandleNodeMessage_Call) Return(_a0 error) *Handler_HandleNodeMessage_Call
func (*Handler_HandleNodeMessage_Call) Run ¶ added in v2.15.0
func (_c *Handler_HandleNodeMessage_Call) Run(run func(ctx context.Context, msg *api.Message, nodeAddr string)) *Handler_HandleNodeMessage_Call
func (*Handler_HandleNodeMessage_Call) RunAndReturn ¶ added in v2.15.0
func (_c *Handler_HandleNodeMessage_Call) RunAndReturn(run func(context.Context, *api.Message, string) error) *Handler_HandleNodeMessage_Call
type Handler_HandleUserMessage_Call ¶ added in v2.15.0
Handler_HandleUserMessage_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'HandleUserMessage'
func (*Handler_HandleUserMessage_Call) Return ¶ added in v2.15.0
func (_c *Handler_HandleUserMessage_Call) Return(_a0 error) *Handler_HandleUserMessage_Call
func (*Handler_HandleUserMessage_Call) Run ¶ added in v2.15.0
func (_c *Handler_HandleUserMessage_Call) Run(run func(ctx context.Context, msg *api.Message, callbackCh chan<- handlers.UserCallbackPayload)) *Handler_HandleUserMessage_Call
func (*Handler_HandleUserMessage_Call) RunAndReturn ¶ added in v2.15.0
func (_c *Handler_HandleUserMessage_Call) RunAndReturn(run func(context.Context, *api.Message, chan<- handlers.UserCallbackPayload) error) *Handler_HandleUserMessage_Call
type Handler_Start_Call ¶ added in v2.15.0
Handler_Start_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Start'
func (*Handler_Start_Call) Return ¶ added in v2.15.0
func (_c *Handler_Start_Call) Return(_a0 error) *Handler_Start_Call
func (*Handler_Start_Call) Run ¶ added in v2.15.0
func (_c *Handler_Start_Call) Run(run func(_a0 context.Context)) *Handler_Start_Call
func (*Handler_Start_Call) RunAndReturn ¶ added in v2.15.0
func (_c *Handler_Start_Call) RunAndReturn(run func(context.Context) error) *Handler_Start_Call