- Timestamp:
- 07/05/2021 05:21:53 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/customize/nav-menu-setting.php
r48939 r51331 71 71 $this->assertNull( $setting->update_status ); 72 72 $this->assertNull( $setting->update_error ); 73 $this->assertI nternalType( 'array',$setting->default );73 $this->assertIsArray( $setting->default ); 74 74 foreach ( array( 'name', 'description', 'parent' ) as $key ) { 75 75 $this->assertArrayHasKey( $key, $setting->default ); … … 150 150 151 151 $value = $setting->value(); 152 $this->assertI nternalType( 'array',$value );152 $this->assertIsArray( $value ); 153 153 foreach ( array( 'name', 'description', 'parent' ) as $key ) { 154 154 $this->assertArrayHasKey( $key, $value ); … … 226 226 $menus_ids = wp_list_pluck( $menus, 'term_id' ); 227 227 $i = array_search( $menu_id, $menus_ids, true ); 228 $this->assertI nternalType( 'int',$i, 'Update-previewed menu does not appear in wp_get_nav_menus()' );228 $this->assertIsInt( $i, 'Update-previewed menu does not appear in wp_get_nav_menus()' ); 229 229 $filtered_menu = $menus[ $i ]; 230 230 $this->assertSame( 'Name 2 \\o/', $filtered_menu->name ); … … 271 271 $menus_ids = wp_list_pluck( $menus, 'term_id' ); 272 272 $i = array_search( $menu_id, $menus_ids, true ); 273 $this->assertI nternalType( 'int',$i, 'Insert-previewed menu was not injected into wp_get_nav_menus()' );273 $this->assertIsInt( $i, 'Insert-previewed menu was not injected into wp_get_nav_menus()' ); 274 274 $filtered_menu = $menus[ $i ]; 275 275 $this->assertSame( 'New Menu Name 1 \\o/', $filtered_menu->name ); … … 305 305 $this->wp_customize->set_post_value( $setting_id, false ); 306 306 307 $this->assertI nternalType( 'array',$setting->value() );308 $this->assertI nternalType( 'object',wp_get_nav_menu_object( $menu_id ) );307 $this->assertIsArray( $setting->value() ); 308 $this->assertIsObject( wp_get_nav_menu_object( $menu_id ) ); 309 309 $setting->preview(); 310 310 $this->assertFalse( $setting->value() );
Note: See TracChangeset
for help on using the changeset viewer.