8000 fix syntax for PHP 7.2 · symfony/http-client@ab3240a · GitHub
[go: up one dir, main page]

Skip to content

Commit ab3240a

Browse files
committed
fix syntax for PHP 7.2
1 parent bc1710e commit ab3240a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Tests/EventSourceHttpClientTest.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class EventSourceHttpClientTest extends TestCase
3434
*/
3535
public function testGetServerSentEvents(string $sep)
3636
{
37-
$data = str_replace("\n", $sep, <<<TXT
37+
$rawData = <<<TXT
3838
event: builderror
3939
id: 46
4040
data: {"foo": "bar"}
@@ -62,7 +62,8 @@ public function testGetServerSentEvents(string $sep)
6262
6363
id: 60
6464
data
65-
TXT);
65+
TXT;
66+
$data = str_replace("\n", $sep, $rawData);
6667

6768
$chunk = new DataChunk(0, $data);
6869
$response = new MockResponse('', ['canceled' => false, 'http_method' => 'GET', 'url' => 'http://localhost:8080/events', 'response_headers' => ['content-type: text/event-stream']]);

0 commit comments

Comments
 (0)
0