- Timestamp:
- 01/05/2023 10:21:19 AM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/rest-plugins-controller.php
r54304 r55029 1140 1140 add_filter( 1141 1141 'pre_http_request', 1142 static function ( $re turn, $args, $url ) use ( $blocked_host ) {1142 static function ( $response, $parsed_args, $url ) use ( $blocked_host ) { 1143 1143 if ( @parse_url( $url, PHP_URL_HOST ) === $blocked_host ) { 1144 1144 return new WP_Error( 'plugins_api_failed', "An expected error occurred connecting to $blocked_host because of a unit test", "cURL error 7: Failed to connect to $blocked_host port 80: Connection refused" ); … … 1146 1146 } 1147 1147 1148 return $re turn;1148 return $response; 1149 1149 }, 1150 1150 10,
Note: See TracChangeset
for help on using the changeset viewer.