Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Added feature to inject custom HTTP clients #84
Take a deep breath...! The very much needed injectable HTTP client handler PR is here! :) This would close #4.
You can inject your own HTTP client in two steps:
I've posted examples of Guzzle and stream wrapper implementations.
use Facebook\FacebookStreamHttpClient; FacebookRequest::setHttpClientHandler(new FacebookStreamHttpClient());
Let me know if you have any questions on anything!
referenced this pull request
May 20, 2014
Great work! Love the idea of injectable HTTP client handler :)
Here's my 2cents:
Hope this is useful and makes sense :)
Whaoo great work ! Much better than what I'd send ;)
Thanks for the feedback guys! :)
@yguedidi Thanks for the code review! I'll def tweak some of your callouts.
On mockery - I included it because it has really become the de facto standard in mocking objects in PHPUnit and has a lot more power and flexibility when mocking an object than PHPUnit's mocking capabilities.
Done! This commit should merge without conflicts.
@yguedidi - On moving the curl bug fix to