<?php namespace Tests\Feature; use Tests\TestCase; use Illuminate\Foundation\Testing\RefreshDatabase; use App\Models\{AttendanceMonthLock,User}; class AttendanceMonthLockTest extends TestCase{use RefreshDatabase;public function test_hr_can_lock_attendance_period():void{$this->seed();$hr=User::where('email','hr@softsuite.local')->first();$this->actingAs($hr)->post(route('attendance.lock'),['period'=>now()->format('Y-m')])->assertRedirect();$this->assertDatabaseHas('attendance_month_locks',['period'=>now()->format('Y-m')]);}}