Changeset 56548 for trunk/tests/phpunit/tests/walker.php
- Timestamp:
- 09/08/2023 10:01:14 AM (3 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/walker.php (modified) (14 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/walker.php
r56547 r56548 32 32 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 33 33 $this->assertSame( '<li>1</li>', $output ); 34 35 34 } 36 35 … … 47 46 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 48 47 $this->assertSame( '<li>1</li>', $output ); 49 50 48 } 51 49 … … 62 60 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 63 61 $this->assertSame( '<li>1</li>', $output ); 64 65 62 } 66 63 … … 82 79 $this->assertSame( 2, $this->walker->get_number_of_root_elements( $items ) ); 83 80 $this->assertSame( '<li>1</li><li>2</li>', $output ); 84 85 81 } 86 82 … … 102 98 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 103 99 $this->assertSame( '<li>1<ul><li>2</li></ul></li>', $output ); 104 105 100 } 106 101 … … 122 117 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 123 118 $this->assertSame( '<li>1</li><li>2</li>', $output ); 124 125 119 } 126 120 … … 142 136 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 143 137 $this->assertSame( '<li>1</li>', $output ); 144 145 138 } 146 139 … … 166 159 $this->assertSame( 1, $this->walker->get_number_of_root_elements( $items ) ); 167 160 $this->assertSame( '<li>1<ul><li>2</li></ul></li>', $output ); 168 169 161 } 170 162 … … 186 178 $this->assertSame( 0, $this->walker->get_number_of_root_elements( $items ) ); 187 179 $this->assertSame( '<li>1<ul><li>2</li></ul></li>', $output ); 188 189 180 } 190 181 … … 202 193 $this->assertSame( 0, $this->walker->get_number_of_root_elements( $items ) ); 203 194 $this->assertSame( '<li>1</li>', $output ); 204 205 195 } 206 196 … … 225 215 // But as we've only asked for the first depth maybe nothing should be returned? 226 216 // $this->assertSame( '', $output ); 227 228 217 } 229 218 … … 249 238 $this->assertSame( 0, $this->walker->get_number_of_root_elements( $items ) ); 250 239 $this->assertSame( '<li>4</li><li>5</li><li>6</li>', $output ); 251 252 240 } 253 241 … … 283 271 // Or maybe all items which are missing parents should simply be treat top level? 284 272 // $this->assertSame( '<li>4</li><li>5</li><li>6</li>', $output ); 285 286 273 } 287 274 … … 313 300 314 301 $this->assertSame( '<li>2</li>', $output ); 315 316 302 } 317 303 }
Note: See TracChangeset
for help on using the changeset viewer.