Changeset 42343 for trunk/tests/phpunit/tests/menu/nav-menu.php
- Timestamp:
- 11/30/2017 11:09:33 PM (8 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/menu/nav-menu.php (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/menu/nav-menu.php
r42026 r42343 36 36 function test_one_location_each() { 37 37 $this->register_nav_menu_locations( array( 'primary' ) ); 38 $prev_theme_nav_menu_locations = array(38 $prev_theme_nav_menu_locations = array( 39 39 'unique-slug' => 1, 40 40 ); … … 56 56 $this->register_nav_menu_locations( array( 'primary', 'secondary' ) ); 57 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,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 66 'secondary' => 2, 67 67 ); … … 77 77 $this->register_nav_menu_locations( array( 'primary', 'secondary' ) ); 78 78 $prev_theme_nav_menu_locations = array( 79 'primary' => 1,79 'primary' => 1, 80 80 'secondary' => 2, 81 81 ); … … 97 97 98 98 $prev_theme_nav_menu_locations = array( 99 'primary' => 1,99 'primary' => 1, 100 100 'secondary' => 2, 101 101 ); … … 129 129 130 130 $expected_nav_menu_locations = array( 131 'primary' => 1,131 'primary' => 1, 132 132 'secondary' => 2, 133 133 ); … … 143 143 $this->register_nav_menu_locations( array( 'primary' ) ); 144 144 $prev_theme_nav_menu_locations = array( 145 'top-menu' => 1,145 'top-menu' => 1, 146 146 'secondary' => 2, 147 147 ); … … 166 166 $prev_theme_nav_menu_locations = array( 167 167 'navigation-menu' => 1, 168 'top-menu' => 2,168 'top-menu' => 2, 169 169 ); 170 170 … … 174 174 $expected_nav_menu_locations = array( 175 175 'primary' => 1, 176 'main' => 2,176 'main' => 2, 177 177 ); 178 178 $this->assertEquals( $expected_nav_menu_locations, $new_next_theme_nav_menu_locations ); … … 188 188 189 189 $prev_theme_nav_menu_locations = array( 190 'main' => 1,191 'secondary' => 2, 192 'tertiary' => 3,190 'main' => 1, 191 'secondary' => 2, 192 'tertiary' => 3, 193 193 ); 194 194
Note: See TracChangeset
for help on using the changeset viewer.