fix: complete InvesteMoz validation and error corrections
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Support;
|
||||
|
||||
use App\Models\User;
|
||||
use Illuminate\Support\Facades\Crypt;
|
||||
|
||||
trait AuthenticatesQaActors
|
||||
{
|
||||
protected function actingAsWithMfa(User $actor): static
|
||||
{
|
||||
$actor->forceFill(['two_factor_secret' => Crypt::encryptString('SYNTHETIC-QA'), 'two_factor_confirmed_at' => now()])->save();
|
||||
|
||||
return $this->actingAs($actor)->withSession(['login.id' => null, 'portal.mfa_actor' => $actor->id, 'portal.mfa_at' => time()]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user