Changeset 41811 for trunk/tests/phpunit/tests/menu/nav-menu.php
- Timestamp:
- 10/10/2017 05:07:31 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/menu/nav-menu.php
r41237 r41811 49 49 50 50 /** 51 * Only registered locations should be mapped and returned. 52 * 53 * @covers wp_map_nav_menu_locations() 54 */ 55 function test_filter_registered_locations() { 56 $this->register_nav_menu_locations( array( 'primary', 'secondary' ) ); 57 $old_next_theme_nav_menu_locations = $prev_theme_nav_menu_locations = array( 58 'primary' => 1, 59 'secondary' => 2, 60 'social' => 3, 61 ); 62 $new_next_theme_nav_menu_locations = wp_map_nav_menu_locations( $old_next_theme_nav_menu_locations, $prev_theme_nav_menu_locations ); 63 64 $expected_nav_menu_locations = array( 65 'primary' => 1, 66 'secondary' => 2, 67 ); 68 $this->assertEquals( $expected_nav_menu_locations, $new_next_theme_nav_menu_locations ); 69 } 70 71 /** 51 72 * Locations with the same name should map, switching to a theme not previously-active. 52 73 *
Note: See TracChangeset
for help on using the changeset viewer.