Help us shape the future of Go! Take the 2026 Go Developer Survey

api

package
v1.25.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2026 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 Client

type Client struct {
	mock.Mock
}

Client is an autogenerated mock type for the Client type

func NewClient

func NewClient(t interface {
	mock.TestingT
	Cleanup(func())
},
) *Client

NewClient creates a new instance of Client. 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 (*Client) Delete

func (_m *Client) Delete(ctx context.Context, path string, headers map[string]string, resp interface{}) error

Delete provides a mock function with given fields: ctx, path, headers, resp

func (*Client) DoAndGetResponseBody

func (_m *Client) DoAndGetResponseBody(ctx context.Context, method string, path string, headers map[string]string, body interface{}) (*http.Response, error)

DoAndGetResponseBody provides a mock function with given fields: ctx, method, path, headers, body

func (*Client) DoWithHeaders

func (_m *Client) DoWithHeaders(ctx context.Context, method string, uri string, headers map[string]string, body interface{}, resp interface{}) error

DoWithHeaders provides a mock function with given fields: ctx, method, uri, headers, body, resp

func (*Client) Get

func (_m *Client) Get(ctx context.Context, path string, headers map[string]string, resp interface{}) error

Get provides a mock function with given fields: ctx, path, headers, resp

func (*Client) GetToken

func (_m *Client) GetToken() string

GetToken provides a mock function with no fields

func (*Client) ParseJSONError

func (_m *Client) ParseJSONError(ctx context.Context, r *http.Response) error

ParseJSONError provides a mock function with given fields: ctx, r

func (*Client) Post

func (_m *Client) Post(ctx context.Context, path string, headers map[string]string, body interface{}, resp interface{}) error

Post provides a mock function with given fields: ctx, path, headers, body, resp

func (*Client) Put

func (_m *Client) Put(ctx context.Context, path string, headers map[string]string, body interface{}, resp interface{}) error

Put provides a mock function with given fields: ctx, path, headers, body, resp

func (*Client) SetToken

func (_m *Client) SetToken(token string)

SetToken provides a mock function with given fields: token

Jump to

Keyboard shortcuts

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