meetup-raffle-winner-picker/tests/FakeEventRepositoryTest.php

21 lines
520 B
PHP
Raw Normal View History

2022-01-13 20:13:28 +00:00
<?php
namespace App\Tests;
use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase;
use Tightenco\Collect\Support\Collection;
2022-01-13 20:13:28 +00:00
2022-01-13 20:29:32 +00:00
final class FakeEventRepositoryTest extends KernelTestCase
2022-01-13 20:13:28 +00:00
{
/** @test */
2022-01-13 20:18:14 +00:00
public function should_only_return_attendees_with_a_yes_rsvp(): void {
$attendees = Collection::make([
2022-01-13 20:28:17 +00:00
['name' => 'matthew s.'],
['name' => 'Michael P.'],
['name' => 'Kathryn "Kat" R.'],
]);
2022-01-13 20:18:14 +00:00
$this->assertCount(3, $attendees->pluck('name'));
2022-01-13 20:13:28 +00:00
}
}