Files
backend/tests/Feature/V2/Dashboard/SafetyAndPrivacy/getAllDataToMapTest.php
2024-04-16 13:17:58 +03:30

41 lines
983 B
PHP

<?php
namespace Tests\Feature\V2\Dashboard\SafetyAndPrivacy;
use App\Models\LogList;
use App\Models\Permission;
use App\Models\SafetyAndPrivacy;
use App\Models\User;
use App\Models\UserActivityLog;
use Illuminate\Foundation\Testing\DatabaseTruncation;
use Tests\TestCase;
class getAllDataToMapTest extends TestCase
{
use DatabaseTruncation;
/**
* A basic feature test example.
*/
public function test_can_see_all_data_to_map(): void
{
$date_from = $this->faker->date;
$date_to = $this->faker->date;
$user = User::factory()
->create();
$response = $this->actingAs($user)->getJson(route('v2.safety_and_privacy.report.map', [
'date_from' => $date_from,
'date_to' => $date_to
]));
$response->assertStatus(200)
->assertJsonStructure([
'status',
'count',
'message',
'data'
]);
}
}