laravel-wordpress-api
laravel-wordpress-api copied to clipboard
Allow custom Http client options
Thanks for the awesome package!
I was using this locally and was getting curl errors:
cURL error 60: SSL certificate problem: unable to get local issuer certificate
After realising that I couldn't modify the verify
option with a globalRequestMiddleware I decided to add a withOptions
method to enable it.
I've updated the README accordingly.
Testing
I spent several hours (I know!) trying to find a way to test this, but with how I'm setting the options there does not seem to be a way that I could find. I source-dived, and xDebugged, but the option seems to be set on the curl instance and with the Fake
I don't think we even get to that depth in the test.
I tried to create a mock, but this felt like we were just testing that the new method does what the new method does.
Happy to take your advice here.
Thanks.