From 9068aa48e24bf271cb6acfbd427bb2dc926b6f8c Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Fri, 8 May 2020 22:52:14 +0200 Subject: [PATCH] [HttpClient] fix dealing with informational response --- .../Component/HttpClient/Response/AmpResponse.php | 2 +- .../Component/HttpClient/Tests/AmpHttpClientTest.php | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/src/Symfony/Component/HttpClient/Response/AmpResponse.php b/src/Symfony/Component/HttpClient/Response/AmpResponse.php index e5d0bb213f..c553dad6de 100644 --- a/src/Symfony/Component/HttpClient/Response/AmpResponse.php +++ b/src/Symfony/Component/HttpClient/Response/AmpResponse.php @@ -200,7 +200,7 @@ final class AmpResponse implements ResponseInterface $options = null; - $activity[$id] = [new FirstChunk()]; + $activity[$id][] = new FirstChunk(); if ('HEAD' === $response->getRequest()->getMethod() || \in_array($info['http_code'], [204, 304], true)) { $activity[$id][] = null; diff --git a/src/Symfony/Component/HttpClient/Tests/AmpHttpClientTest.php b/src/Symfony/Component/HttpClient/Tests/AmpHttpClientTest.php index c3bdbed0aa..e17b45a0ce 100644 --- a/src/Symfony/Component/HttpClient/Tests/AmpHttpClientTest.php +++ b/src/Symfony/Component/HttpClient/Tests/AmpHttpClientTest.php @@ -25,13 +25,4 @@ class AmpHttpClientTest extends HttpClientTestCase { $this->markTestSkipped('A real proxy server would be needed.'); } - - public function testInformationalResponseStream() - { - if (getenv('TRAVIS_PULL_REQUEST')) { - $this->markTestIncomplete('This test always fails on Travis.'); - } - - parent::testInformationalResponseStream(); - } }