diff --git a/tests/rest/test-rest-api.php b/tests/rest/test-rest-api.php index 34cac041..4e30edaf 100644 --- a/tests/rest/test-rest-api.php +++ b/tests/rest/test-rest-api.php @@ -489,6 +489,7 @@ private function convert_next_error_to_exception() { // This method is now deprecated. Use this workaround to convert the next error // to an exception, which can be matched with expectExceptionMessage(). + // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_set_error_handler -- Used for catching errors in tests. set_error_handler( static function ( int $errno, string $errstr ): never { restore_error_handler();