mocks

package
v0.0.0-...-9c9e09e Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2022 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMockHTTPClient

func NewMockHTTPClient(fn RoundTripFunc) *http.Client

func NewMockUserRepository

func NewMockUserRepository(t *testing.T) *repos.UserRepository

NewMockUserRepository returns an actual repos.UserRepository system with fake data in a temporary directory.

Types

type RoundTripFunc

type RoundTripFunc func(req *http.Request) *http.Response

func (RoundTripFunc) RoundTrip

func (f RoundTripFunc) RoundTrip(req *http.Request) (*http.Response, error)

Jump to

Keyboard shortcuts

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