How can I dump all garbage responses to txt files?

I read the documentation:

http://guzzle3.readthedocs.org/testing/unit-testing.html

and I know how to use .txt files as response mocks for testing; but what I want to achieve is to capture the actual responses of my application. My webapp relies on hundreds of different API calls, and when one fails it's hard to know where the failure is, so I want to use the .txt response files to "enter" a working response for debugging purposes.

Hope it's clear enough

early.

+3
php mocking phpunit stub guzzle


source to share


No one has answered this question yet

Check out similar questions:

2776
How can I prevent SQL injection in PHP?
158
How can I use Guzzle to send a POST request in JSON?
105
Injecting layout into AngularJS service
94
Guzzle 6: no more json () response method
2
Check my database for all unit tests in PHPUnit
2
PHPUnit: Is it possible to mock a php function to return a mocked object in place of a normal object?
1
C # Mock IHttpclient & CreateClient
1
Why is my Perl unit test not working in EPIC but working in the debugger?
1
PHPUnit Measuring class constant
0
How to prevent intercepted Guzzle 3 request from making DNS lookups?



All Articles
Loading...
X
Show
Funny
Dev
Pics