mock

package
v0.46.1 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2026 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type WebsocketConnection

type WebsocketConnection struct {
	mock.Mock
}

WebsocketConnection is an autogenerated mock type for the WebsocketConnection type

func NewWebsocketConnection

func NewWebsocketConnection(t interface {
	mock.TestingT
	Cleanup(func())
}) *WebsocketConnection

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

func (_mock *WebsocketConnection) Close() error

Close provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) EXPECT added in v0.46.0

func (*WebsocketConnection) ReadJSON

func (_mock *WebsocketConnection) ReadJSON(v interface{}) error

ReadJSON provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) SetPongHandler

func (_mock *WebsocketConnection) SetPongHandler(h func(string) error)

SetPongHandler provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) SetReadDeadline

func (_mock *WebsocketConnection) SetReadDeadline(deadline time.Time) error

SetReadDeadline provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) SetWriteDeadline

func (_mock *WebsocketConnection) SetWriteDeadline(deadline time.Time) error

SetWriteDeadline provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) WriteControl

func (_mock *WebsocketConnection) WriteControl(messageType int, deadline time.Time) error

WriteControl provides a mock function for the type WebsocketConnection

func (*WebsocketConnection) WriteJSON

func (_mock *WebsocketConnection) WriteJSON(v interface{}) error

WriteJSON provides a mock function for the type WebsocketConnection

type WebsocketConnection_Close_Call added in v0.46.0

type WebsocketConnection_Close_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_Close_Call) Return added in v0.46.0

func (*WebsocketConnection_Close_Call) Run added in v0.46.0

func (*WebsocketConnection_Close_Call) RunAndReturn added in v0.46.0

type WebsocketConnection_Expecter added in v0.46.0

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

func (*WebsocketConnection_Expecter) Close added in v0.46.0

Close is a helper method to define mock.On call

func (*WebsocketConnection_Expecter) ReadJSON added in v0.46.0

ReadJSON is a helper method to define mock.On call

  • v interface{}

func (*WebsocketConnection_Expecter) SetPongHandler added in v0.46.0

func (_e *WebsocketConnection_Expecter) SetPongHandler(h interface{}) *WebsocketConnection_SetPongHandler_Call

SetPongHandler is a helper method to define mock.On call

  • h func(string) error

func (*WebsocketConnection_Expecter) SetReadDeadline added in v0.46.0

func (_e *WebsocketConnection_Expecter) SetReadDeadline(deadline interface{}) *WebsocketConnection_SetReadDeadline_Call

SetReadDeadline is a helper method to define mock.On call

  • deadline time.Time

func (*WebsocketConnection_Expecter) SetWriteDeadline added in v0.46.0

func (_e *WebsocketConnection_Expecter) SetWriteDeadline(deadline interface{}) *WebsocketConnection_SetWriteDeadline_Call

SetWriteDeadline is a helper method to define mock.On call

  • deadline time.Time

func (*WebsocketConnection_Expecter) WriteControl added in v0.46.0

func (_e *WebsocketConnection_Expecter) WriteControl(messageType interface{}, deadline interface{}) *WebsocketConnection_WriteControl_Call

WriteControl is a helper method to define mock.On call

  • messageType int
  • deadline time.Time

func (*WebsocketConnection_Expecter) WriteJSON added in v0.46.0

WriteJSON is a helper method to define mock.On call

  • v interface{}

type WebsocketConnection_ReadJSON_Call added in v0.46.0

type WebsocketConnection_ReadJSON_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_ReadJSON_Call) Return added in v0.46.0

func (*WebsocketConnection_ReadJSON_Call) Run added in v0.46.0

func (_c *WebsocketConnection_ReadJSON_Call) Run(run func(v interface{})) *WebsocketConnection_ReadJSON_Call

func (*WebsocketConnection_ReadJSON_Call) RunAndReturn added in v0.46.0

func (_c *WebsocketConnection_ReadJSON_Call) RunAndReturn(run func(v interface{}) error) *WebsocketConnection_ReadJSON_Call

type WebsocketConnection_SetPongHandler_Call added in v0.46.0

type WebsocketConnection_SetPongHandler_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_SetPongHandler_Call) Return added in v0.46.0

func (*WebsocketConnection_SetPongHandler_Call) Run added in v0.46.0

func (*WebsocketConnection_SetPongHandler_Call) RunAndReturn added in v0.46.0

type WebsocketConnection_SetReadDeadline_Call added in v0.46.0

type WebsocketConnection_SetReadDeadline_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_SetReadDeadline_Call) Return added in v0.46.0

func (*WebsocketConnection_SetReadDeadline_Call) Run added in v0.46.0

func (*WebsocketConnection_SetReadDeadline_Call) RunAndReturn added in v0.46.0

type WebsocketConnection_SetWriteDeadline_Call added in v0.46.0

type WebsocketConnection_SetWriteDeadline_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_SetWriteDeadline_Call) Return added in v0.46.0

func (*WebsocketConnection_SetWriteDeadline_Call) Run added in v0.46.0

func (*WebsocketConnection_SetWriteDeadline_Call) RunAndReturn added in v0.46.0

type WebsocketConnection_WriteControl_Call added in v0.46.0

type WebsocketConnection_WriteControl_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_WriteControl_Call) Return added in v0.46.0

func (*WebsocketConnection_WriteControl_Call) Run added in v0.46.0

func (*WebsocketConnection_WriteControl_Call) RunAndReturn added in v0.46.0

func (_c *WebsocketConnection_WriteControl_Call) RunAndReturn(run func(messageType int, deadline time.Time) error) *WebsocketConnection_WriteControl_Call

type WebsocketConnection_WriteJSON_Call added in v0.46.0

type WebsocketConnection_WriteJSON_Call struct {
	*mock.Call
}

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

func (*WebsocketConnection_WriteJSON_Call) Return added in v0.46.0

func (*WebsocketConnection_WriteJSON_Call) Run added in v0.46.0

func (*WebsocketConnection_WriteJSON_Call) RunAndReturn added in v0.46.0

func (_c *WebsocketConnection_WriteJSON_Call) RunAndReturn(run func(v interface{}) error) *WebsocketConnection_WriteJSON_Call

Jump to

Keyboard shortcuts

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