Closed valters-tomsons closed 4 years ago
Hi could you show me the test set up please.
Hi, this is the test in question: https://github.com/FaithLV/spectabis-next/blob/master/Tests/ServiceTests/Integration/GetGameBoxArtTest.cs
Hi there.. Yeah my bad. The framework actually creates a new instance of your HTTP client to insert logging code in via a message handler. I'd forgotten to copy across the default headers. here is a link to the code
Thanks for the feedback.
Fix should be in version 4.0.1.
Cheers Stuart.
Endpoint I am trying to test requires authorization key in headers. For some reason, Bard does not inherit headers added to HttpClient.
Here is how I am setting the Header value
I am reusing the same HttpClient I use in my application, calling like this inherits headers mentioned above.
Only difference I noticed is I am using
SendAsync(method, route)
instead ofGetAsync(route)
, but I tried replacing the call withSendAsync
and that did not work.