ajout app
This commit is contained in:
16
SNIPE-IT/tests/Support/InteractsWithAuthentication.php
Normal file
16
SNIPE-IT/tests/Support/InteractsWithAuthentication.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Support;
|
||||
|
||||
use Illuminate\Contracts\Auth\Authenticatable;
|
||||
use Laravel\Passport\Passport;
|
||||
|
||||
trait InteractsWithAuthentication
|
||||
{
|
||||
protected function actingAsForApi(Authenticatable $user)
|
||||
{
|
||||
Passport::actingAs($user);
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user