Added another base test

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe 2024-06-22 20:37:49 +01:00
parent 3a05d72124
commit c1be94c4ad

View file

@ -45,12 +45,8 @@ class RestoreUserTest extends TestCase
public function testSuccessPermissionsForRestoringUserViaApi() public function testSuccessPermissionsForRestoringUserViaApi()
{ {
$deleted_user = User::factory()->deletedUser()->create(); $deleted_user = User::factory()->deletedUser()->create();
\Log::warning($deleted_user);
$admin = User::factory()->deleteUsers()->create(); $this->actingAsForApi(User::factory()->admin()->create())
\Log::warning($admin->permissions);
$this->actingAsForApi($admin)
->postJson(route('api.users.restore', ['user' => $deleted_user])) ->postJson(route('api.users.restore', ['user' => $deleted_user]))
->assertOk() ->assertOk()
->assertStatus(200) ->assertStatus(200)