From 56ec94e20c6524b757aee258c7da1ba209b212cd Mon Sep 17 00:00:00 2001 From: Volodymyr Kolesnykov Date: Wed, 27 Sep 2023 18:55:01 +0300 Subject: [PATCH] test: address `http_api_transports` deprecation in WP 6.4 (#4903) --- tests/files/test-curl-streamer.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/files/test-curl-streamer.php b/tests/files/test-curl-streamer.php index 1640bd1f35..654bf18cf5 100644 --- a/tests/files/test-curl-streamer.php +++ b/tests/files/test-curl-streamer.php @@ -31,6 +31,13 @@ public function tearDown(): void { } public function test__init() { + global $wp_version; + + $version = preg_replace( '/-.*$/', '', $wp_version ); + if ( version_compare( $version, '6.4', '>=' ) ) { + $this->setExpectedDeprecated( 'http_api_transports' ); + } + $expected_transport = 'WP_Http_Curl'; $wp_http = new \WP_Http();