From 5c840d93bb833cd1ba5834499a602edc4530545f Mon Sep 17 00:00:00 2001 From: Jb Audras Date: Fri, 3 Feb 2023 13:51:11 +0000 Subject: [PATCH] HTTP API: Fix a unit test failure found after [55210]. Follow-up to [55210]. See #54225. git-svn-id: https://develop.svn.wordpress.org/trunk@55211 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/upgrade.php | 2 +- tests/phpunit/tests/functions/doEnclose.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/includes/upgrade.php b/src/wp-admin/includes/upgrade.php index 9c4cb43580..63580cceb0 100644 --- a/src/wp-admin/includes/upgrade.php +++ b/src/wp-admin/includes/upgrade.php @@ -512,7 +512,7 @@ function wp_install_maybe_enable_pretty_permalinks() { * can block head requests. */ $response = wp_remote_get( $test_url, array( 'timeout' => 5 ) ); - $x_pingback_header = wp_remote_retrieve_header( $response, 'X-Pingback' ); + $x_pingback_header = wp_remote_retrieve_header( $response, 'x-pingback' ); $pretty_permalinks = $x_pingback_header && get_bloginfo( 'pingback_url' ) === $x_pingback_header; if ( $pretty_permalinks ) { diff --git a/tests/phpunit/tests/functions/doEnclose.php b/tests/phpunit/tests/functions/doEnclose.php index 4d1a2ee818..e907f179df 100644 --- a/tests/phpunit/tests/functions/doEnclose.php +++ b/tests/phpunit/tests/functions/doEnclose.php @@ -271,8 +271,8 @@ class Tests_Functions_DoEnclose extends WP_UnitTestCase { ), 'ogg' => array( 'headers' => array( - 'content-length' => 321, - 'content-type' => 'audio/ogg', + 'Content-Length' => 321, + 'Content-Type' => 'audio/ogg', ), ), );