make(['google_id' => 'g-123', 'github_id' => null]); expect($user->isConnectedTo(SocialAuthProvider::Google))->toBeTrue(); expect($user->isConnectedTo(SocialAuthProvider::GitHub))->toBeFalse(); }); test('firstName returns the first token of the display name', function (string $name, string $expected) { expect(User::factory()->make(['name' => $name])->firstName())->toBe($expected); })->with([ ['Paulo Castellano', 'Paulo'], ['Ada', 'Ada'], [' Marie Curie ', 'Marie'], ['', ''], [' ', ''], ]);