mocks

package
v2.15.0-rc0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 6, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConnectionAcceptor added in v2.3.0

type ConnectionAcceptor struct {
	mock.Mock
}

ConnectionAcceptor is an autogenerated mock type for the ConnectionAcceptor type

func NewConnectionAcceptor added in v2.3.0

func NewConnectionAcceptor(t interface {
	mock.TestingT
	Cleanup(func())
}) *ConnectionAcceptor

NewConnectionAcceptor creates a new instance of ConnectionAcceptor. 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 (*ConnectionAcceptor) AbortHandshake added in v2.3.0

func (_m *ConnectionAcceptor) AbortHandshake(attemptId string)

AbortHandshake provides a mock function with given fields: attemptId

func (*ConnectionAcceptor) EXPECT added in v2.15.0

func (*ConnectionAcceptor) FinalizeHandshake added in v2.3.0

func (_m *ConnectionAcceptor) FinalizeHandshake(attemptId string, response []byte, conn *websocket.Conn) error

FinalizeHandshake provides a mock function with given fields: attemptId, response, conn

func (*ConnectionAcceptor) StartHandshake added in v2.3.0

func (_m *ConnectionAcceptor) StartHandshake(authHeader []byte) (string, []byte, error)

StartHandshake provides a mock function with given fields: authHeader

type ConnectionAcceptor_AbortHandshake_Call added in v2.15.0

type ConnectionAcceptor_AbortHandshake_Call struct {
	*mock.Call
}

ConnectionAcceptor_AbortHandshake_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AbortHandshake'

func (*ConnectionAcceptor_AbortHandshake_Call) Return added in v2.15.0

func (*ConnectionAcceptor_AbortHandshake_Call) Run added in v2.15.0

func (*ConnectionAcceptor_AbortHandshake_Call) RunAndReturn added in v2.15.0

type ConnectionAcceptor_Expecter added in v2.15.0

type ConnectionAcceptor_Expecter struct {
	// contains filtered or unexported fields
}

func (*ConnectionAcceptor_Expecter) AbortHandshake added in v2.15.0

func (_e *ConnectionAcceptor_Expecter) AbortHandshake(attemptId interface{}) *ConnectionAcceptor_AbortHandshake_Call

AbortHandshake is a helper method to define mock.On call

  • attemptId string

func (*ConnectionAcceptor_Expecter) FinalizeHandshake added in v2.15.0

func (_e *ConnectionAcceptor_Expecter) FinalizeHandshake(attemptId interface{}, response interface{}, conn interface{}) *ConnectionAcceptor_FinalizeHandshake_Call

FinalizeHandshake is a helper method to define mock.On call

  • attemptId string
  • response []byte
  • conn *websocket.Conn

func (*ConnectionAcceptor_Expecter) StartHandshake added in v2.15.0

func (_e *ConnectionAcceptor_Expecter) StartHandshake(authHeader interface{}) *ConnectionAcceptor_StartHandshake_Call

StartHandshake is a helper method to define mock.On call

  • authHeader []byte

type ConnectionAcceptor_FinalizeHandshake_Call added in v2.15.0

type ConnectionAcceptor_FinalizeHandshake_Call struct {
	*mock.Call
}

ConnectionAcceptor_FinalizeHandshake_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FinalizeHandshake'

func (*ConnectionAcceptor_FinalizeHandshake_Call) Return added in v2.15.0

func (*ConnectionAcceptor_FinalizeHandshake_Call) Run added in v2.15.0

func (*ConnectionAcceptor_FinalizeHandshake_Call) RunAndReturn added in v2.15.0

type ConnectionAcceptor_StartHandshake_Call added in v2.15.0

type ConnectionAcceptor_StartHandshake_Call struct {
	*mock.Call
}

ConnectionAcceptor_StartHandshake_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'StartHandshake'

func (*ConnectionAcceptor_StartHandshake_Call) Return added in v2.15.0

func (*ConnectionAcceptor_StartHandshake_Call) Run added in v2.15.0

func (*ConnectionAcceptor_StartHandshake_Call) RunAndReturn added in v2.15.0

type ConnectionInitiator added in v2.3.0

type ConnectionInitiator struct {
	mock.Mock
}

ConnectionInitiator is an autogenerated mock type for the ConnectionInitiator type

func NewConnectionInitiator added in v2.3.0

func NewConnectionInitiator(t interface {
	mock.TestingT
	Cleanup(func())
}) *ConnectionInitiator

NewConnectionInitiator creates a new instance of ConnectionInitiator. 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 (*ConnectionInitiator) ChallengeResponse added in v2.3.0

func (_m *ConnectionInitiator) ChallengeResponse(_a0 *url.URL, challenge []byte) ([]byte, error)

ChallengeResponse provides a mock function with given fields: _a0, challenge

func (*ConnectionInitiator) EXPECT added in v2.15.0

func (*ConnectionInitiator) NewAuthHeader added in v2.3.0

func (_m *ConnectionInitiator) NewAuthHeader(_a0 *url.URL) ([]byte, error)

NewAuthHeader provides a mock function with given fields: _a0

type ConnectionInitiator_ChallengeResponse_Call added in v2.15.0

type ConnectionInitiator_ChallengeResponse_Call struct {
	*mock.Call
}

ConnectionInitiator_ChallengeResponse_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ChallengeResponse'

func (*ConnectionInitiator_ChallengeResponse_Call) Return added in v2.15.0

func (*ConnectionInitiator_ChallengeResponse_Call) Run added in v2.15.0

func (*ConnectionInitiator_ChallengeResponse_Call) RunAndReturn added in v2.15.0

type ConnectionInitiator_Expecter added in v2.15.0

type ConnectionInitiator_Expecter struct {
	// contains filtered or unexported fields
}

func (*ConnectionInitiator_Expecter) ChallengeResponse added in v2.15.0

func (_e *ConnectionInitiator_Expecter) ChallengeResponse(_a0 interface{}, challenge interface{}) *ConnectionInitiator_ChallengeResponse_Call

ChallengeResponse is a helper method to define mock.On call

  • _a0 *url.URL
  • challenge []byte

func (*ConnectionInitiator_Expecter) NewAuthHeader added in v2.15.0

func (_e *ConnectionInitiator_Expecter) NewAuthHeader(_a0 interface{}) *ConnectionInitiator_NewAuthHeader_Call

NewAuthHeader is a helper method to define mock.On call

  • _a0 *url.URL

type ConnectionInitiator_NewAuthHeader_Call added in v2.15.0

type ConnectionInitiator_NewAuthHeader_Call struct {
	*mock.Call
}

ConnectionInitiator_NewAuthHeader_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NewAuthHeader'

func (*ConnectionInitiator_NewAuthHeader_Call) Return added in v2.15.0

func (*ConnectionInitiator_NewAuthHeader_Call) Run added in v2.15.0

func (*ConnectionInitiator_NewAuthHeader_Call) RunAndReturn added in v2.15.0

type HTTPRequestHandler added in v2.3.0

type HTTPRequestHandler struct {
	mock.Mock
}

HTTPRequestHandler is an autogenerated mock type for the HTTPRequestHandler type

func NewHTTPRequestHandler added in v2.3.0

func NewHTTPRequestHandler(t interface {
	mock.TestingT
	Cleanup(func())
}) *HTTPRequestHandler

NewHTTPRequestHandler creates a new instance of HTTPRequestHandler. 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 (*HTTPRequestHandler) EXPECT added in v2.15.0

func (*HTTPRequestHandler) ProcessRequest added in v2.3.0

func (_m *HTTPRequestHandler) ProcessRequest(ctx context.Context, rawRequest []byte) ([]byte, int)

ProcessRequest provides a mock function with given fields: ctx, rawRequest

type HTTPRequestHandler_Expecter added in v2.15.0

type HTTPRequestHandler_Expecter struct {
	// contains filtered or unexported fields
}

func (*HTTPRequestHandler_Expecter) ProcessRequest added in v2.15.0

func (_e *HTTPRequestHandler_Expecter) ProcessRequest(ctx interface{}, rawRequest interface{}) *HTTPRequestHandler_ProcessRequest_Call

ProcessRequest is a helper method to define mock.On call

  • ctx context.Context
  • rawRequest []byte

type HTTPRequestHandler_ProcessRequest_Call added in v2.15.0

type HTTPRequestHandler_ProcessRequest_Call struct {
	*mock.Call
}

HTTPRequestHandler_ProcessRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ProcessRequest'

func (*HTTPRequestHandler_ProcessRequest_Call) Return added in v2.15.0

func (*HTTPRequestHandler_ProcessRequest_Call) Run added in v2.15.0

func (*HTTPRequestHandler_ProcessRequest_Call) RunAndReturn added in v2.15.0

type HttpServer

type HttpServer struct {
	mock.Mock
}

HttpServer is an autogenerated mock type for the HttpServer type

func NewHttpServer

func NewHttpServer(t interface {
	mock.TestingT
	Cleanup(func())
}) *HttpServer

NewHttpServer creates a new instance of HttpServer. 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 (*HttpServer) Close

func (_m *HttpServer) Close() error

Close provides a mock function with given fields:

func (*HttpServer) EXPECT added in v2.15.0

func (_m *HttpServer) EXPECT() *HttpServer_Expecter

func (*HttpServer) GetPort added in v2.3.0

func (_m *HttpServer) GetPort() int

GetPort provides a mock function with given fields:

func (*HttpServer) SetHTTPRequestHandler

func (_m *HttpServer) SetHTTPRequestHandler(handler network.HTTPRequestHandler)

SetHTTPRequestHandler provides a mock function with given fields: handler

func (*HttpServer) Start

func (_m *HttpServer) Start(_a0 context.Context) error

Start provides a mock function with given fields: _a0

type HttpServer_Close_Call added in v2.15.0

type HttpServer_Close_Call struct {
	*mock.Call
}

HttpServer_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'

func (*HttpServer_Close_Call) Return added in v2.15.0

func (*HttpServer_Close_Call) Run added in v2.15.0

func (_c *HttpServer_Close_Call) Run(run func()) *HttpServer_Close_Call

func (*HttpServer_Close_Call) RunAndReturn added in v2.15.0

func (_c *HttpServer_Close_Call) RunAndReturn(run func() error) *HttpServer_Close_Call

type HttpServer_Expecter added in v2.15.0

type HttpServer_Expecter struct {
	// contains filtered or unexported fields
}

func (*HttpServer_Expecter) Close added in v2.15.0

Close is a helper method to define mock.On call

func (*HttpServer_Expecter) GetPort added in v2.15.0

GetPort is a helper method to define mock.On call

func (*HttpServer_Expecter) SetHTTPRequestHandler added in v2.15.0

func (_e *HttpServer_Expecter) SetHTTPRequestHandler(handler interface{}) *HttpServer_SetHTTPRequestHandler_Call

SetHTTPRequestHandler is a helper method to define mock.On call

  • handler network.HTTPRequestHandler

func (*HttpServer_Expecter) Start added in v2.15.0

func (_e *HttpServer_Expecter) Start(_a0 interface{}) *HttpServer_Start_Call

Start is a helper method to define mock.On call

  • _a0 context.Context

type HttpServer_GetPort_Call added in v2.15.0

type HttpServer_GetPort_Call struct {
	*mock.Call
}

HttpServer_GetPort_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPort'

func (*HttpServer_GetPort_Call) Return added in v2.15.0

func (*HttpServer_GetPort_Call) Run added in v2.15.0

func (_c *HttpServer_GetPort_Call) Run(run func()) *HttpServer_GetPort_Call

func (*HttpServer_GetPort_Call) RunAndReturn added in v2.15.0

func (_c *HttpServer_GetPort_Call) RunAndReturn(run func() int) *HttpServer_GetPort_Call

type HttpServer_SetHTTPRequestHandler_Call added in v2.15.0

type HttpServer_SetHTTPRequestHandler_Call struct {
	*mock.Call
}

HttpServer_SetHTTPRequestHandler_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetHTTPRequestHandler'

func (*HttpServer_SetHTTPRequestHandler_Call) Return added in v2.15.0

func (*HttpServer_SetHTTPRequestHandler_Call) Run added in v2.15.0

func (*HttpServer_SetHTTPRequestHandler_Call) RunAndReturn added in v2.15.0

type HttpServer_Start_Call added in v2.15.0

type HttpServer_Start_Call struct {
	*mock.Call
}

HttpServer_Start_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Start'

func (*HttpServer_Start_Call) Return added in v2.15.0

func (*HttpServer_Start_Call) Run added in v2.15.0

func (*HttpServer_Start_Call) RunAndReturn added in v2.15.0

func (_c *HttpServer_Start_Call) RunAndReturn(run func(context.Context) error) *HttpServer_Start_Call

type WebSocketServer

type WebSocketServer struct {
	mock.Mock
}

WebSocketServer is an autogenerated mock type for the WebSocketServer type

func NewWebSocketServer

func NewWebSocketServer(t interface {
	mock.TestingT
	Cleanup(func())
}) *WebSocketServer

NewWebSocketServer creates a new instance of WebSocketServer. 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 (*WebSocketServer) Close

func (_m *WebSocketServer) Close() error

Close provides a mock function with given fields:

func (*WebSocketServer) EXPECT added in v2.15.0

func (*WebSocketServer) GetPort added in v2.3.0

func (_m *WebSocketServer) GetPort() int

GetPort provides a mock function with given fields:

func (*WebSocketServer) Start

func (_m *WebSocketServer) Start(_a0 context.Context) error

Start provides a mock function with given fields: _a0

type WebSocketServer_Close_Call added in v2.15.0

type WebSocketServer_Close_Call struct {
	*mock.Call
}

WebSocketServer_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'

func (*WebSocketServer_Close_Call) Return added in v2.15.0

func (*WebSocketServer_Close_Call) Run added in v2.15.0

func (*WebSocketServer_Close_Call) RunAndReturn added in v2.15.0

func (_c *WebSocketServer_Close_Call) RunAndReturn(run func() error) *WebSocketServer_Close_Call

type WebSocketServer_Expecter added in v2.15.0

type WebSocketServer_Expecter struct {
	// contains filtered or unexported fields
}

func (*WebSocketServer_Expecter) Close added in v2.15.0

Close is a helper method to define mock.On call

func (*WebSocketServer_Expecter) GetPort added in v2.15.0

GetPort is a helper method to define mock.On call

func (*WebSocketServer_Expecter) Start added in v2.15.0

func (_e *WebSocketServer_Expecter) Start(_a0 interface{}) *WebSocketServer_Start_Call

Start is a helper method to define mock.On call

  • _a0 context.Context

type WebSocketServer_GetPort_Call added in v2.15.0

type WebSocketServer_GetPort_Call struct {
	*mock.Call
}

WebSocketServer_GetPort_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPort'

func (*WebSocketServer_GetPort_Call) Return added in v2.15.0

func (*WebSocketServer_GetPort_Call) Run added in v2.15.0

func (*WebSocketServer_GetPort_Call) RunAndReturn added in v2.15.0

func (_c *WebSocketServer_GetPort_Call) RunAndReturn(run func() int) *WebSocketServer_GetPort_Call

type WebSocketServer_Start_Call added in v2.15.0

type WebSocketServer_Start_Call struct {
	*mock.Call
}

WebSocketServer_Start_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Start'

func (*WebSocketServer_Start_Call) Return added in v2.15.0

func (*WebSocketServer_Start_Call) Run added in v2.15.0

func (*WebSocketServer_Start_Call) RunAndReturn added in v2.15.0

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL