<?php

namespace Tests\Unit\Models;

use App\Models\AttendanceRecord;
use PHPUnit\Framework\TestCase;

class AttendanceRecordTest extends TestCase
{
    public function test_model_metadata_is_converted(): void
    {
        $model = new AttendanceRecord();

        $this->assertSame('attendance_record', $model->getTable());
        $this->assertSame('id', $model->getKeyName());
        $this->assertSame(true, $model->timestamps);
        $this->assertSame(["class_section_id", "student_id", "school_id", "total_absence", "total_late", "total_presence", "total_attendance", "semester", "school_year", "modified_by", "created_at", "updated_at"], $model->getFillable());
    }

    public function test_model_class_loads(): void
    {
        $this->assertInstanceOf(AttendanceRecord::class, new AttendanceRecord());
    }
}
