File tree 1 file changed +8
-4
lines changed
1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 3
3
namespace Http \Mock ;
4
4
5
5
use Http \Client \Common \HttpAsyncClientEmulator ;
6
- use Http \Client \Common \VersionBridgeClient ;
7
6
use Http \Client \Exception ;
8
7
use Http \Client \HttpAsyncClient ;
9
8
use Http \Client \HttpClient ;
26
25
class Client implements HttpClient, HttpAsyncClient
27
26
{
28
27
use HttpAsyncClientEmulator;
29
- use VersionBridgeClient;
30
28
31
29
/**
32
30
* @var ResponseFactory|ResponseFactoryInterface
@@ -78,9 +76,15 @@ public function __construct($responseFactory = null)
78
76
}
79
77
80
78
/**
81
- * {@inheritdoc}
79
+ * Respond with the prepared behaviour, in the following order.
80
+ *
81
+ * - Throw the next exception in the list and advance
82
+ * - Return the next response in the list and advance
83
+ * - Throw the default exception if set (forever)
84
+ * - Return the default response if set (forever)
85
+ * - Create a new empty response with the response factory
82
86
*/
83
- public function doSendRequest (RequestInterface $ request )
87
+ public function sendRequest (RequestInterface $ request ): ResponseInterface
84
88
{
85
89
$ this ->requests [] = $ request ;
86
90
You can’t perform that action at this time.
0 commit comments