mocks

package
v1.17.11 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPRequest

type HTTPRequest struct {
	mock.Mock
}

HTTPRequest is an autogenerated mock type for the HTTPRequest type

func NewHTTPRequest added in v1.11.21

func NewHTTPRequest(t interface {
	mock.TestingT
	Cleanup(func())
}) *HTTPRequest

NewHTTPRequest creates a new instance of HTTPRequest. 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 (*HTTPRequest) Do

func (_m *HTTPRequest) Do(_a0 context.Context, method string, url string, reqBody []byte, headers map[string]string) ([]byte, int, error)

Do provides a mock function with given fields: _a0, method, url, reqBody, headers

func (*HTTPRequest) DoRequest added in v1.11.6

func (_m *HTTPRequest) DoRequest(ctx context.Context, method string, url string, requestBody []byte, headers map[string]string) (*candiutils.HTTPRequestResult, error)

DoRequest provides a mock function with given fields: ctx, method, url, requestBody, headers

type WorkerPool added in v1.17.2

type WorkerPool[T interface{}] struct {
	mock.Mock
}

WorkerPool is an autogenerated mock type for the WorkerPool type

func NewWorkerPool added in v1.17.2

func NewWorkerPool[T interface{}](t interface {
	mock.TestingT
	Cleanup(func())
}) *WorkerPool[T]

NewWorkerPool creates a new instance of WorkerPool. 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 (*WorkerPool[T]) AddJob added in v1.17.2

func (_m *WorkerPool[T]) AddJob(job T)

AddJob provides a mock function with given fields: job

func (*WorkerPool[T]) Dispatch added in v1.17.2

func (_m *WorkerPool[T]) Dispatch(ctx context.Context, jobFunc func(context.Context, T))

Dispatch provides a mock function with given fields: ctx, jobFunc

func (*WorkerPool[T]) Finish added in v1.17.2

func (_m *WorkerPool[T]) Finish()

Finish provides a mock function with given fields:

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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