test

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package test provides shared test utils

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPService

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

func NewTestService

func NewTestService(t *testing.T, serverURL string) *HTTPService

func (*HTTPService) Authorization

func (t *HTTPService) Authorization() string

func (*HTTPService) Close

func (t *HTTPService) Close()

func (*HTTPService) DoHTTPRequest

func (*HTTPService) DoHTTPRequestWithResponse

func (t *HTTPService) DoHTTPRequestWithResponse(_ *http.Request, _ http2.RequestCallback) (*http.Response, error)

func (*HTTPService) DoPostRequest

func (t *HTTPService) DoPostRequest(_ context.Context, url string, body io.Reader, requestCallback http2.RequestCallback, _ http2.ResponseCallback) *http2.Error

func (*HTTPService) GetRequest

func (*HTTPService) HTTPClient

func (t *HTTPService) HTTPClient() *http.Client

func (*HTTPService) Lines

func (t *HTTPService) Lines() []string

func (*HTTPService) ReplyError

func (t *HTTPService) ReplyError() *http2.Error

func (*HTTPService) ServerAPIURL

func (t *HTTPService) ServerAPIURL() string

func (*HTTPService) ServerURL

func (t *HTTPService) ServerURL() string

func (*HTTPService) SetAuthorization

func (t *HTTPService) SetAuthorization(_ string)

func (*HTTPService) SetReplyError

func (t *HTTPService) SetReplyError(replyError *http2.Error)

func (*HTTPService) SetWasGzip

func (t *HTTPService) SetWasGzip(wasGzip bool)

func (*HTTPService) WasGzip

func (t *HTTPService) WasGzip() bool

Jump to

Keyboard shortcuts

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