Changeset 54215 for trunk/tests/phpunit/tests/admin/wpPostsListTable.php
- Timestamp:
- 09/19/2022 09:06:08 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/admin/wpPostsListTable.php
r51997 r54215 320 320 } 321 321 322 /** 323 * @ticket 42066 324 * 325 * @covers WP_Posts_List_Table::get_views 326 */ 327 public function test_get_views_should_return_views_by_default() { 328 global $avail_post_stati; 329 330 $avail_post_stati_backup = $avail_post_stati; 331 $avail_post_stati = get_available_post_statuses(); 332 333 $actual = $this->table->get_views(); 334 $avail_post_stati = $avail_post_stati_backup; 335 336 $expected = array( 337 'all' => '<a href="edit.php?post_type=page">All <span class="count">(38)</span></a>', 338 'publish' => '<a href="edit.php?post_status=publish&post_type=page">Published <span class="count">(38)</span></a>', 339 ); 340 341 $this->assertSame( $expected, $actual ); 342 } 343 322 344 }
Note: See TracChangeset
for help on using the changeset viewer.