linting, fmt

This commit is contained in:
tsmethurst 2021-04-26 21:22:34 +02:00
commit dda2c9ab1c
4 changed files with 11 additions and 11 deletions

View file

@ -43,15 +43,15 @@ func NewTestTransportController(db db.DB, client pub.HttpClient) transport.Contr
// NewMockHTTPClient returns a client that conforms to the pub.HttpClient interface,
// but will always just execute the given `do` function, allowing responses to be mocked.
func NewMockHTTPClient(do func(req *http.Request) (*http.Response, error)) pub.HttpClient {
return &mockHttpClient{
return &mockHTTPClient{
do: do,
}
}
type mockHttpClient struct {
type mockHTTPClient struct {
do func(req *http.Request) (*http.Response, error)
}
func (m *mockHttpClient) Do(req *http.Request) (*http.Response, error) {
func (m *mockHTTPClient) Do(req *http.Request) (*http.Response, error) {
return m.do(req)
}