fix bug auth login fail
WMS API/ERP-API/pipeline/head This commit looks good
Details
WMS API/ERP-API/pipeline/head This commit looks good
Details
This commit is contained in:
parent
c445ee43e3
commit
3fda04a881
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
namespace App\Repositories\Auth;
|
||||
|
||||
use Illuminate\Validation\ValidationException;
|
||||
use App\Models\User;
|
||||
use Hash;
|
||||
|
||||
|
|
|
|||
|
|
@ -26,4 +26,19 @@ class LoginTest extends TestCase
|
|||
|
||||
$response->assertStatus(200);
|
||||
}
|
||||
|
||||
/**
|
||||
* A basic feature test example.
|
||||
*/
|
||||
public function test_fail(): void
|
||||
{
|
||||
$user = User::factory()->create();
|
||||
|
||||
$response = $this->post('/auth/login',[
|
||||
"email" => $user->email,
|
||||
"password" => "fail",
|
||||
]);
|
||||
|
||||
$response->assertStatus(422);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue