refactor(engine): *http.Client -> model.HTTPClient (#836)

This diff makes the implementation of the engine package more
abstract by changing HTTPClient() to return a model.HTTPClient
as opposed to returning an *http.Client.

Part of https://github.com/ooni/probe/issues/2184
This commit is contained in:
Simone Basso 2022-07-08 11:08:10 +02:00 committed by GitHub
commit 6019b25baf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 9 deletions

View file

@ -337,7 +337,7 @@ func (s *Session) GetTestHelpersByName(name string) ([]model.OOAPIService, bool)
}
// DefaultHTTPClient returns the session's default HTTP client.
func (s *Session) DefaultHTTPClient() *http.Client {
func (s *Session) DefaultHTTPClient() model.HTTPClient {
return &http.Client{Transport: s.httpDefaultTransport}
}