Changeset 47122 for trunk/tests/phpunit/tests/admin/includesScreen.php
- Timestamp:
- 01/29/2020 12:43:23 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/admin/includesScreen.php
r46586 r47122 246 246 function test_post_type_with_special_suffix_as_hookname() { 247 247 register_post_type( 'value-add' ); 248 $screen = convert_to_screen( 'value-add' ); // the -addpart is key.248 $screen = convert_to_screen( 'value-add' ); // The '-add' part is key. 249 249 $this->assertEquals( $screen->post_type, 'value-add' ); 250 250 $this->assertEquals( $screen->base, 'post' ); … … 252 252 $this->assertFalse( $screen->is_block_editor ); // Post types do not support `show_in_rest` by default. 253 253 254 $screen = convert_to_screen( 'edit-value-add' ); // the -addpart is key.254 $screen = convert_to_screen( 'edit-value-add' ); // The '-add' part is key. 255 255 $this->assertEquals( $screen->post_type, 'value-add' ); 256 256 $this->assertEquals( $screen->base, 'edit' ); … … 261 261 function test_taxonomy_with_special_suffix_as_hookname() { 262 262 register_taxonomy( 'old-or-new', 'post' ); 263 $screen = convert_to_screen( 'edit-old-or-new' ); // the -newpart is key.263 $screen = convert_to_screen( 'edit-old-or-new' ); // The '-new' part is key. 264 264 $this->assertEquals( $screen->taxonomy, 'old-or-new' ); 265 265 $this->assertEquals( $screen->base, 'edit-tags' ); … … 370 370 'content' => 'some content', 371 371 'callback' => false, 372 // Don't include a priority 372 // Don't include a priority. 373 373 ); 374 374 375 375 $screen = get_current_screen(); 376 376 377 // add help tabs.377 // Add help tabs. 378 378 379 379 $screen->add_help_tab( $tab_1_args ); … … 387 387 388 388 $screen->add_help_tab( $tab_4_args ); 389 // Priority is added with the default for future calls 389 // Priority is added with the default for future calls. 390 390 $tab_4_args['priority'] = 10; 391 391 $this->assertEquals( $screen->get_help_tab( $tab_4 ), $tab_4_args );
Note: See TracChangeset
for help on using the changeset viewer.