<?php

namespace Tests\Unit;

use App\Enums\CouponStatus;
use App\Enums\CouponType;
use App\Filament\Resources\Coupons\Schemas\CouponInfolist;
use Tests\TestCase;

class CouponInfolistTest extends TestCase
{
    public function test_it_formats_enum_states(): void
    {
        $this->assertSame(CouponType::PERCENTAGE->label(), CouponInfolist::formatEnumState(CouponType::PERCENTAGE));
        $this->assertSame(CouponStatus::ACTIVE->label(), CouponInfolist::formatEnumState(CouponStatus::ACTIVE));
        $this->assertSame('Flat', CouponInfolist::formatEnumState('flat'));
        $this->assertSame('', CouponInfolist::formatEnumState(null));
    }
}
