Be more explicit in test case

This commit is contained in:
Marcus Moore 2023-02-06 16:06:13 -08:00
parent 0e57e4836e
commit c03079944a
No known key found for this signature in database

View file

@ -52,12 +52,12 @@ class UsersForSelectListTest extends TestCase
$results = collect($response->json('results'));
$this->assertEquals($jedi->users->count(), $results->count());
$this->assertEquals(3, $results->count());
$this->assertTrue(
$results->pluck('text')->contains(fn($text) => str_contains($text, $jedi->users->first()->first_name))
$results->pluck('text')->contains(fn($text) => str_contains($text, 'Luke'))
);
$this->assertFalse(
$results->pluck('text')->contains(fn($text) => str_contains($text, $sith->users->first()->first_name))
$results->pluck('text')->contains(fn($text) => str_contains($text, 'Darth'))
);
}