Skip to content

Commit a4f71e7

Browse files
Merge branch '4.4'
* 4.4: (27 commits) [Validator] add notice in UPGRADE file for new Range constraint option [CssSelector] Support *:only-of-type pseudo class selector [Intl] Update the ICU data to 65.1 (4.4 branch) [Intl] Update the ICU data to 65.1 (4.3 branch) Replace deprecated calls in tests [Intl] Update the ICU data to 65.1 Delete 5_Security_issue.md [DI] Whitelist error_renderer.renderer tag in UnusedTagsPass [DI] Whitelist validator.auto_mapper in UnusedTagsPass Update CHANGELOG.md [HttpClient] Fixed #33832 NO_PROXY option ignored in NativeHttpClient::request() method [EventDispatcher] A compiler pass for aliased userland events. [Cache] give 100ms before starting the expiration countdown [Cache] fix logger usage in CacheTrait::doGet() [VarDumper] fix dumping uninitialized SplFileInfo Added missing translations. [Form] Added CountryType option for using alpha3 country codes Fixed invalid changelog 4.0.0 for VarDumper [Workflow] Fixed BC break on WorkflowInterface Fix wrong expression language value ...
2 parents 92ceb25 + 8ee3882 commit a4f71e7

File tree

5 files changed

+10
-10
lines changed

5 files changed

+10
-10
lines changed

NativeHttpClient.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ public function request(string $method, string $url, array $options = []): Respo
221221
];
222222

223223
$proxy = self::getProxy($options['proxy'], $url);
224-
$noProxy = $_SERVER['no_proxy'] ?? $_SERVER['NO_PROXY'] ?? '';
224+
$noProxy = $options['no_proxy'] ?? $_SERVER['no_proxy'] ?? $_SERVER['NO_PROXY'] ?? '';
225225
$noProxy = $noProxy ? preg_split('/[\s,]+/', $noProxy) : [];
226226

227227
$resolveRedirect = self::createRedirectResolver($options, $host, $proxy, $noProxy, $info, $onProgress);

Tests/DataCollector/HttpClientDataCollectorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ public function testItIsEmptyAfterReset()
164164
$this->assertEquals(0, $sut->getRequestCount());
165165
}
166166

167-
private function httpClientThatHasTracedRequests($tracedRequests)
167+
private function httpClientThatHasTracedRequests($tracedRequests): TraceableHttpClient
168168
{
169169
$httpClient = new TraceableHttpClient(new NativeHttpClient());
170170

Tests/Exception/HttpExceptionTraitTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
*/
2121
class HttpExceptionTraitTest extends TestCase
2222
{
23-
public function provideParseError()
23+
public function provideParseError(): iterable
2424
{
2525
yield ['application/ld+json', '{"hydra:title": "An error occurred", "hydra:description": "Some details"}'];
2626
yield ['application/problem+json', '{"title": "An error occurred", "detail": "Some details"}'];

Tests/HttpClientTraitTest.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class HttpClientTraitTest extends TestCase
2424
/**
2525
* @dataProvider providePrepareRequestUrl
2626
*/
27-
public function testPrepareRequestUrl($expected, $url, $query = [])
27+
public function testPrepareRequestUrl(string $expected, string $url, array $query = [])
2828
{
2929
$defaults = [
3030
'base_uri' => 'http://example.com?c=c',
@@ -36,7 +36,7 @@ public function testPrepareRequestUrl($expected, $url, $query = [])
3636
$this->assertSame($expected, implode('', $url));
3737
}
3838

39-
public function providePrepareRequestUrl()
39+
public function providePrepareRequestUrl(): iterable
4040
{
4141
yield ['http://example.com/', 'http://example.com/'];
4242
yield ['http://example.com/?a=1&b=b', '.'];
@@ -48,15 +48,15 @@ public function providePrepareRequestUrl()
4848
/**
4949
* @dataProvider provideResolveUrl
5050
*/
51-
public function testResolveUrl($base, $url, $expected)
51+
public function testResolveUrl(string $base, string $url, string $expected)
5252
{
5353
$this->assertSame($expected, implode('', self::resolveUrl(self::parseUrl($url), self::parseUrl($base))));
5454
}
5555

5656
/**
5757
* From https://github.com/guzzle/psr7/blob/master/tests/UriResoverTest.php.
5858
*/
59-
public function provideResolveUrl()
59+
public function provideResolveUrl(): array
6060
{
6161
return [
6262
[self::RFC3986_BASE, 'http:h', 'http:h'],
@@ -123,14 +123,14 @@ public function provideResolveUrl()
123123
/**
124124
* @dataProvider provideParseUrl
125125
*/
126-
public function testParseUrl($expected, $url, $query = [])
126+
public function testParseUrl(array $expected, string $url, array $query = [])
127127
{
128128
$expected = array_combine(['scheme', 'authority', 'path', 'query', 'fragment'], $expected);
129129

130130
$this->assertSame($expected, self::parseUrl($url, $query));
131131
}
132132

133-
public function provideParseUrl()
133+
public function provideParseUrl(): iterable
134134
{
135135
yield [['http:', '//example.com', null, null, null], 'http://Example.coM:80'];
136136
yield [['https:', '//xn--dj-kia8a.example.com:8000', '/', null, null], 'https://DÉjà.Example.com:8000/'];

Tests/HttpOptionsTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
*/
2020
class HttpOptionsTest extends TestCase
2121
{
22-
public function provideSetAuthBasic()
22+
public function provideSetAuthBasic(): iterable
2323
{
2424
yield ['user:password', 'user', 'password'];
2525
yield ['user:password', 'user:password'];

0 commit comments

Comments
 (0)