Changeset 52010 for trunk/tests/phpunit/tests/admin/includesScreen.php
- Timestamp:
- 11/04/2021 03:22:47 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/admin/includesScreen.php
r51639 r52010 156 156 ); 157 157 158 function tear_down() {158 public function tear_down() { 159 159 unset( $GLOBALS['wp_taxonomies']['old-or-new'] ); 160 160 parent::tear_down(); 161 161 } 162 162 163 function test_set_current_screen_with_hook_suffix() {163 public function test_set_current_screen_with_hook_suffix() { 164 164 global $current_screen; 165 165 … … 229 229 } 230 230 231 function test_post_type_as_hookname() {231 public function test_post_type_as_hookname() { 232 232 $screen = convert_to_screen( 'page' ); 233 233 $this->assertSame( $screen->post_type, 'page' ); … … 237 237 } 238 238 239 function test_post_type_with_special_suffix_as_hookname() {239 public function test_post_type_with_special_suffix_as_hookname() { 240 240 register_post_type( 'value-add' ); 241 241 $screen = convert_to_screen( 'value-add' ); // The '-add' part is key. … … 252 252 } 253 253 254 function test_taxonomy_with_special_suffix_as_hookname() {254 public function test_taxonomy_with_special_suffix_as_hookname() { 255 255 register_taxonomy( 'old-or-new', 'post' ); 256 256 $screen = convert_to_screen( 'edit-old-or-new' ); // The '-new' part is key. … … 261 261 } 262 262 263 function test_post_type_with_edit_prefix() {263 public function test_post_type_with_edit_prefix() { 264 264 register_post_type( 'edit-some-thing' ); 265 265 $screen = convert_to_screen( 'edit-some-thing' ); … … 276 276 } 277 277 278 function test_post_type_edit_collisions() {278 public function test_post_type_edit_collisions() { 279 279 register_post_type( 'comments' ); 280 280 register_post_type( 'tags' ); … … 296 296 } 297 297 298 function test_help_tabs() {298 public function test_help_tabs() { 299 299 $tab = __FUNCTION__; 300 300 $tab_args = array( … … 332 332 * @ticket 19828 333 333 */ 334 function test_help_tabs_priority() {334 public function test_help_tabs_priority() { 335 335 $tab_1 = 'tab1'; 336 336 $tab_1_args = array( … … 428 428 * @ticket 25799 429 429 */ 430 function test_options() {430 public function test_options() { 431 431 $option = __FUNCTION__; 432 432 $option_args = array( … … 452 452 } 453 453 454 function test_in_admin() {454 public function test_in_admin() { 455 455 set_current_screen( 'edit.php' ); 456 456 $this->assertTrue( get_current_screen()->in_admin() );
Note: See TracChangeset
for help on using the changeset viewer.