From 1fc5e7c0bacebeba1463cdc5b6441287cebbea82 Mon Sep 17 00:00:00 2001 From: gggeek Date: Sun, 14 Apr 2024 22:25:23 +0000 Subject: [PATCH] fix https tests on php 8.3 --- tests/09HTTPTest.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/09HTTPTest.php b/tests/09HTTPTest.php index 71cb63c7..536e30f4 100644 --- a/tests/09HTTPTest.php +++ b/tests/09HTTPTest.php @@ -295,7 +295,7 @@ class HTTPTest extends ServerTest if (version_compare(PHP_VERSION, '8.0', '>=') && $this->args['SSLVERSION'] == 0) { $version = explode('.', PHP_VERSION); - $this->client->setSSLVersion(4 + $version[1]); + $this->client->setSSLVersion(min(4 + $version[1], 7)); } $this->$method(); @@ -349,7 +349,7 @@ class HTTPTest extends ServerTest /// @todo we should probably look deeper into the Apache config / ssl version in use to find out why this /// does not work well with TLS < 1.2 if ($this->args['SSLVERSION'] == 0) { - $this->client->setSSLVersion(5 + $version[1]); + $this->client->setSSLVersion(min(5 + $version[1], 7)); } } $this->$method(); @@ -389,7 +389,7 @@ class HTTPTest extends ServerTest if (version_compare(PHP_VERSION, '8.0', '>=') && $this->args['SSLVERSION'] == 0) { $version = explode('.', PHP_VERSION); - $this->client->setSSLVersion(4 + $version[1]); + $this->client->setSSLVersion(min(4 + $version[1], 7)); } $this->$method(); -- 2.47.0