Skip to content

Commit

Permalink
Fix class name in WP_REST_Global_Styles_Controller_Gutenberg_Test com…
Browse files Browse the repository at this point in the history
…ments
  • Loading branch information
ajlende committed Feb 1, 2024
1 parent f50f857 commit da92f2e
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions phpunit/class-wp-rest-global-styles-controller-gutenberg-test.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php
/**
* Unit tests covering WP_REST_Global_Styles_Controller functionality.
* Unit tests covering WP_REST_Global_Styles_Controller_Gutenberg functionality.
*
* @package Gutenberg
*
* @covers WP_REST_Global_Styles_Controller
* @covers WP_REST_Global_Styles_Controller_Gutenberg
*/
class WP_REST_Global_Styles_Controller_Gutenberg_Test extends WP_Test_REST_Controller_Testcase {
/**
Expand Down Expand Up @@ -76,7 +76,7 @@ public static function wpTearDownAfterClass() {
}

/**
* @covers WP_REST_Global_Styles_Controller::register_routes
* @covers WP_REST_Global_Styles_Controller_Gutenberg::register_routes
*/
public function test_register_routes() {
$routes = rest_get_server()->get_routes();
Expand Down Expand Up @@ -163,7 +163,7 @@ public function test_get_items() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*/
public function test_get_theme_item_no_user() {
wp_set_current_user( 0 );
Expand All @@ -173,7 +173,7 @@ public function test_get_theme_item_no_user() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*/
public function test_get_theme_item_permission_check() {
wp_set_current_user( self::$subscriber_id );
Expand All @@ -183,7 +183,7 @@ public function test_get_theme_item_permission_check() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*/
public function test_get_theme_item_invalid() {
wp_set_current_user( self::$admin_id );
Expand All @@ -194,7 +194,7 @@ public function test_get_theme_item_invalid() {

/**
* @dataProvider data_get_theme_item_invalid_theme_dirname
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*
* @param string $theme_dirname Theme directory to test.
* @param string $expected Expected error code.
Expand Down Expand Up @@ -253,7 +253,7 @@ public function data_get_theme_item_invalid_theme_dirname() {

/**
* @dataProvider data_get_theme_item
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*
* @param string $theme Theme directory to test.
*/
Expand Down Expand Up @@ -310,7 +310,7 @@ public function data_get_theme_item() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_theme_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_theme_item
*/
public function test_get_theme_item_fields() {
wp_set_current_user( self::$admin_id );
Expand All @@ -323,7 +323,7 @@ public function test_get_theme_item_fields() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item_no_user() {
wp_set_current_user( 0 );
Expand All @@ -333,7 +333,7 @@ public function test_get_item_no_user() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item_invalid_post() {
wp_set_current_user( self::$admin_id );
Expand All @@ -343,7 +343,7 @@ public function test_get_item_invalid_post() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item_permission_check() {
wp_set_current_user( self::$subscriber_id );
Expand All @@ -353,7 +353,7 @@ public function test_get_item_permission_check() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item_no_user_edit() {
wp_set_current_user( 0 );
Expand All @@ -364,7 +364,7 @@ public function test_get_item_no_user_edit() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item_permission_check_edit() {
wp_set_current_user( self::$subscriber_id );
Expand All @@ -375,7 +375,7 @@ public function test_get_item_permission_check_edit() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item
*/
public function test_get_item() {
wp_set_current_user( self::$admin_id );
Expand Down Expand Up @@ -409,7 +409,7 @@ public function test_create_item() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item() {
wp_set_current_user( self::$admin_id );
Expand All @@ -425,7 +425,7 @@ public function test_update_item() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item_no_user() {
wp_set_current_user( 0 );
Expand All @@ -435,7 +435,7 @@ public function test_update_item_no_user() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item_invalid_post() {
wp_set_current_user( self::$admin_id );
Expand All @@ -445,7 +445,7 @@ public function test_update_item_invalid_post() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item_permission_check() {
wp_set_current_user( self::$subscriber_id );
Expand All @@ -455,7 +455,7 @@ public function test_update_item_permission_check() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item_valid_styles_css() {
wp_set_current_user( self::$admin_id );
Expand All @@ -474,7 +474,7 @@ public function test_update_item_valid_styles_css() {
}

/**
* @covers WP_REST_Global_Styles_Controller::update_item
* @covers WP_REST_Global_Styles_Controller_Gutenberg::update_item
*/
public function test_update_item_invalid_styles_css() {
wp_set_current_user( self::$admin_id );
Expand Down Expand Up @@ -506,7 +506,7 @@ public function test_prepare_item() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_item_schema
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_item_schema
*/
public function test_get_item_schema() {
$request = new WP_REST_Request( 'OPTIONS', '/wp/v2/global-styles/' . self::$global_styles_id );
Expand All @@ -521,7 +521,7 @@ public function test_get_item_schema() {
}

/**
* @covers WP_REST_Global_Styles_Controller::get_available_actions
* @covers WP_REST_Global_Styles_Controller_Gutenberg::get_available_actions
*/
public function test_assign_edit_css_action_admin() {
wp_set_current_user( self::$admin_id );
Expand Down

0 comments on commit da92f2e

Please sign in to comment.