InteractsWithAuthentication
trait InteractsWithAuthentication
Methods
Set the currently logged in user for the application.
Set the currently logged in user for the application.
Assert that the user is authenticated.
Assert that the user is not authenticated.
Return true if the user is authenticated, false otherwise.
Assert that the user is authenticated as the given user.
Assert that the given credentials are valid.
Assert that the given credentials are invalid.
Return true if the credentials are valid, false otherwise.
Details
at line 16
$this
actingAs(Authenticatable $user, string|null $driver = null)
Set the currently logged in user for the application.
at line 30
void
be(Authenticatable $user, string|null $driver = null)
Set the currently logged in user for the application.
at line 43
$this
seeIsAuthenticated(string|null $guard = null)
Assert that the user is authenticated.
at line 56
$this
dontSeeIsAuthenticated(string|null $guard = null)
Assert that the user is not authenticated.
at line 69
protected bool
isAuthenticated(string|null $guard = null)
Return true if the user is authenticated, false otherwise.
at line 81
$this
seeIsAuthenticatedAs($user, string|null $guard = null)
Assert that the user is authenticated as the given user.
at line 105
$this
seeCredentials(array $credentials, string|null $guard = null)
Assert that the given credentials are valid.
at line 121
$this
dontSeeCredentials(array $credentials, string|null $guard = null)
Assert that the given credentials are invalid.
at line 137
protected bool
hasCredentials(array $credentials, string|null $guard = null)
Return true if the credentials are valid, false otherwise.