mock

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2023 License: GPL-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 HttpServerStub

type HttpServerStub struct {
	ListenAndServeCalled func() error
	ShutdownCalled       func(ctx context.Context) error
}

HttpServerStub -

func (*HttpServerStub) ListenAndServe

func (h *HttpServerStub) ListenAndServe() error

ListenAndServe -

func (*HttpServerStub) Shutdown

func (h *HttpServerStub) Shutdown(ctx context.Context) error

Shutdown -

type Uint64ByteSliceConverterStub

type Uint64ByteSliceConverterStub struct {
	ToByteSliceCalled func(u2 uint64) []byte
	ToUint64Called    func(bytes []byte) (uint64, error)
}

Uint64ByteSliceConverterStub -

func (*Uint64ByteSliceConverterStub) IsInterfaceNil

func (u *Uint64ByteSliceConverterStub) IsInterfaceNil() bool

IsInterfaceNil -

func (*Uint64ByteSliceConverterStub) ToByteSlice

func (u *Uint64ByteSliceConverterStub) ToByteSlice(u2 uint64) []byte

ToByteSlice -

func (*Uint64ByteSliceConverterStub) ToUint64

func (u *Uint64ByteSliceConverterStub) ToUint64(bytes []byte) (uint64, error)

ToUint64 -

type WebSocketSenderStub

type WebSocketSenderStub struct {
	SendOnRouteCalled func(args data.WsSendArgs) error
	AddClientCalled   func(wss data.WSConn, remoteAddr string)
	CloseCalled       func() error
}

WebSocketSenderStub -

func (*WebSocketSenderStub) AddClient

func (w *WebSocketSenderStub) AddClient(wss data.WSConn, remoteAddr string)

AddClient -

func (*WebSocketSenderStub) Close

func (w *WebSocketSenderStub) Close() error

Close -

func (*WebSocketSenderStub) IsInterfaceNil

func (w *WebSocketSenderStub) IsInterfaceNil() bool

IsInterfaceNil -

func (*WebSocketSenderStub) Send

func (w *WebSocketSenderStub) Send(args data.WsSendArgs) error

Send -

type WebsocketConnectionStub

type WebsocketConnectionStub struct {
	ReadMessageCalled  func() (messageType int, payload []byte, err error)
	WriteMessageCalled func(messageType int, data []byte) error
	CloseCalled        func() error
}

WebsocketConnectionStub -

func (*WebsocketConnectionStub) Close

func (w *WebsocketConnectionStub) Close() error

Close -

func (*WebsocketConnectionStub) ReadMessage

func (w *WebsocketConnectionStub) ReadMessage() (messageType int, payload []byte, err error)

ReadMessage -

func (*WebsocketConnectionStub) WriteMessage

func (w *WebsocketConnectionStub) WriteMessage(messageType int, data []byte) error

WriteMessage -

Jump to

Keyboard shortcuts

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