import { describe, it, expect } from 'vitest'
import { 
  OrganizationalLevel, 
  PersonnelLevel, 
  PersonnelStatus, 
  ApprovalStatus, 
  ApprovalRequestType 
} from './index'

describe('Type Enums', () => {
  describe('OrganizationalLevel', () => {
    it('should have correct values for organizational hierarchy', () => {
      expect(OrganizationalLevel.Division).toBe(1)
      expect(OrganizationalLevel.Regiment).toBe(2)
      expect(OrganizationalLevel.Battalion).toBe(3)
      expect(OrganizationalLevel.Company).toBe(4)
    })

    it('should maintain hierarchy order (Division > Regiment > Battalion > Company)', () => {
      expect(OrganizationalLevel.Division).toBeLessThan(OrganizationalLevel.Regiment)
      expect(OrganizationalLevel.Regiment).toBeLessThan(OrganizationalLevel.Battalion)
      expect(OrganizationalLevel.Battalion).toBeLessThan(OrganizationalLevel.Company)
    })
  })

  describe('PersonnelLevel', () => {
    it('should have correct values matching organizational levels', () => {
      expect(PersonnelLevel.Division).toBe(1)
      expect(PersonnelLevel.Regiment).toBe(2)
      expect(PersonnelLevel.Battalion).toBe(3)
      expect(PersonnelLevel.Company).toBe(4)
    })

    it('should correspond to OrganizationalLevel values', () => {
      expect(PersonnelLevel.Division).toBe(OrganizationalLevel.Division)
      expect(PersonnelLevel.Regiment).toBe(OrganizationalLevel.Regiment)
      expect(PersonnelLevel.Battalion).toBe(OrganizationalLevel.Battalion)
      expect(PersonnelLevel.Company).toBe(OrganizationalLevel.Company)
    })
  })

  describe('PersonnelStatus', () => {
    it('should have correct status values', () => {
      expect(PersonnelStatus.Pending).toBe('Pending')
      expect(PersonnelStatus.Approved).toBe('Approved')
      expect(PersonnelStatus.Rejected).toBe('Rejected')
    })
  })

  describe('ApprovalStatus', () => {
    it('should have correct status values', () => {
      expect(ApprovalStatus.Pending).toBe('Pending')
      expect(ApprovalStatus.Approved).toBe('Approved')
      expect(ApprovalStatus.Rejected).toBe('Rejected')
    })
  })

  describe('ApprovalRequestType', () => {
    it('should have correct type values', () => {
      expect(ApprovalRequestType.AllocationModification).toBe('AllocationModification')
      expect(ApprovalRequestType.ReportModification).toBe('ReportModification')
      expect(ApprovalRequestType.PersonnelModification).toBe('PersonnelModification')
    })
  })
})
