mocklab

package
v0.0.0-...-bbeba4f Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustWriteHTTPResponse

func MustWriteHTTPResponse(t *testing.T, w io.Writer, fixturePath string)

func Setup

func Setup(t *testing.T) (*http.ServeMux, *httptest.Server, *gitlab.Client)

Setup sets up a test HTTP server along with a gitlab.Client that is configured to talk to that test server. Tests should register handlers on mux which provide mock responses for the API method being tested.

func Teardown

func Teardown(server *httptest.Server)

Teardown closes the test HTTP server.

Types

This section is empty.

Jump to

Keyboard shortcuts

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