We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 1eb7ee4 + 809a5f4 commit 2340b78Copy full SHA for 2340b78
Test/HttpClientTestCase.php
@@ -152,6 +152,16 @@ public function testClientError()
152
$this->assertSame(404, $response->getStatusCode());
153
$this->assertSame(['application/json'], $response->getHeaders(false)['content-type']);
154
$this->assertNotEmpty($response->getContent(false));
155
+
156
+ $response = $client->request('GET', 'http://localhost:8057/404');
157
158
+ try {
159
+ foreach ($client->stream($response) as $chunk) {
160
+ $this->assertTrue($chunk->isFirst());
161
+ }
162
+ $this->fail(ClientExceptionInterface::class.' expected');
163
+ } catch (ClientExceptionInterface $e) {
164
165
}
166
167
public function testIgnoreErrors()
0 commit comments