- Timestamp:
- 11/29/2022 03:49:49 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/rest-api/rest-taxonomies-controller.php
r54090 r54891 175 175 public function test_prepare_item() { 176 176 $tax = get_taxonomy( 'category' ); 177 $endpoint = new WP_REST_Taxonomies_Controller ;178 $request = new WP_REST_Request ;177 $endpoint = new WP_REST_Taxonomies_Controller(); 178 $request = new WP_REST_Request(); 179 179 $request->set_param( 'context', 'edit' ); 180 180 $response = $endpoint->prepare_item_for_response( $tax, $request ); … … 184 184 public function test_prepare_item_limit_fields() { 185 185 $tax = get_taxonomy( 'category' ); 186 $request = new WP_REST_Request ;187 $endpoint = new WP_REST_Taxonomies_Controller ;186 $request = new WP_REST_Request(); 187 $endpoint = new WP_REST_Taxonomies_Controller(); 188 188 $request->set_param( 'context', 'edit' ); 189 189 $request->set_param( '_fields', 'id,name' );
Note: See TracChangeset
for help on using the changeset viewer.