Skip to content

Commit

Permalink
minor #31308 [HttpClient] fix skipping h2push test case (nicolas-grekas)
Browse files Browse the repository at this point in the history
This PR was merged into the 4.3-dev branch.

Discussion
----------

[HttpClient] fix skipping h2push test case

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #30975
| License       | MIT
| Doc PR        | -

Commits
-------

3aaa742 [HttpClient] fix skipping h2push test case
  • Loading branch information
fabpot committed Apr 29, 2019
2 parents 584c21b + 3aaa742 commit 002b48d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/Symfony/Component/HttpClient/Tests/CurlHttpClientTest.php
Expand Up @@ -28,16 +28,15 @@ protected function getHttpClient(string $testCase): HttpClientInterface

/**
* @requires PHP 7.2.17
* @requires extension curl 7.61
*/
public function testHttp2Push()
{
if (\PHP_VERSION_ID >= 70300 && \PHP_VERSION_ID < 70304) {
$this->markTestSkipped('PHP 7.3.0 to 7.3.3 don\'t support HTTP/2 PUSH');
}

if (!\defined('CURLMOPT_PUSHFUNCTION') || !(CURL_VERSION_HTTP2 & curl_version()['features'])) {
$this->markTestSkipped('curl is not compiled with support for HTTP/2 PUSH');
if (!\defined('CURLMOPT_PUSHFUNCTION') || 0x073d00 > ($v = curl_version())['version_number'] || !(CURL_VERSION_HTTP2 & $v['features'])) {
$this->markTestSkipped('curl <7.61 is used or it is not compiled with support for HTTP/2 PUSH');
}

$logger = new class() extends AbstractLogger {
Expand Down

0 comments on commit 002b48d

Please sign in to comment.