You appear to be a bot. Output may be restricted
Description
Test: get_events() shouldn't stick an extra WordCamp when there's already one that naturally falls into the list.
Usage
Tests_Admin_wpCommunityEvents::test_trim_events_dont_pin_multiple_wordcamps();
Parameters
Returns
void
Source
File name: wordpress-develop-tests/phpunit/tests/admin/wpCommunityEvents.php
Lines:
1 to 16 of 16
public function test_trim_events_dont_pin_multiple_wordcamps() { $trim_events = new ReflectionMethod( $this->instance, 'trim_events' ); $trim_events->setAccessible( true ); $actual = $trim_events->invoke( $this->instance, $this->_events_with_multiple_wordcamps() ); /* * The first meetup should be removed because it's expired, while the next 3 events are selected. * WordCamp LA should not be stuck to the list, because San Diego already appears naturally. */ $this->assertCount( 3, $actual ); $this->assertSame( $actual[0]['title'], 'WordCamp San Diego' ); $this->assertSame( $actual[1]['title'], 'Part 3- Site Maintenance - Tools to Make It Easy' ); $this->assertSame( $actual[2]['title'], 'WordPress Q&A' ); }