summaryrefslogtreecommitdiffstats
path: root/php-guzzlehttp-ringphp-upstream-pull-42.patch
blob: 6439a36cbe3b9321ca87e329843de77b9b753b18 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
From 6218c409739ab2db2a2c9d30d56925fd1936dff6 Mon Sep 17 00:00:00 2001
From: Remi Collet <fedora@famillecollet.com>
Date: Fri, 31 Mar 2017 08:29:47 +0200
Subject: [PATCH] Fix #41 use proper proxy attribute without ending /

---
 tests/Client/StreamHandlerTest.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/Client/StreamHandlerTest.php b/tests/Client/StreamHandlerTest.php
index 3cb9a8e..d491064 100644
--- a/tests/Client/StreamHandlerTest.php
+++ b/tests/Client/StreamHandlerTest.php
@@ -375,7 +375,7 @@ public function testEmitsProgressInformationAndDebugInformation()
 
     public function testAddsProxyByProtocol()
     {
-        $url = str_replace('http', 'tcp', Server::$url);
+        $url = rtrim(str_replace('http', 'tcp', Server::$url), '/');
         $res = $this->getSendResult(['proxy' => ['http' => $url]]);
         $opts = stream_context_get_options($res['body']);
         $this->assertEquals($url, $opts['http']['proxy']);