Closed Fritte795 closed 8 months ago
Hi @Fritte795, it looks good to me, but could you please resolve the conflict first?
@tranhoangvuit I will fix this conflicts tonight
This PR clobbered the changes made in #41
In current main you cannot set apikey and token separately.
What kind of change does this PR introduce?
Add the possibility to define custom transport settings for the
http.Client
. Furthermore the renaming prevents stuttering (formerClient.clientTransport
)What is the current behavior?
Any information can be found in #39
What is the new behavior?
It is now possible to define custom transport behavior by setting
Client.Transport.Parent
:Additional information
Due to the behavior of
httpmock
used for testing, the implementedRoundTrip()
is not as clean as it could be. For testing withhttpmock
to work properlyhttp.DefaultTransport.RoundTrip()
must be called inRoundTrip()
inclient.go
.