square-php-sdk icon indicating copy to clipboard operation
square-php-sdk copied to clipboard

Support mocking of `HttpClient` in `SquareClient

Open amitsnyderman opened this issue 3 years ago • 0 comments

It would be helpful for testing SDK integrations to be able to provide a mock HttpClientInterface implementation. The Square\SquareClient constructor explicitly builds an Unirest\HttpClient making it challenging to inject alternative behavior.

Or if you have an another approach / suggestion for mocking SquareClient...

amitsnyderman avatar Nov 07 '22 16:11 amitsnyderman