|
| 1 | +# Unit tests for il_ihwap_income_eligible |
| 2 | +# Income eligibility: |
| 3 | +# Sizes 1-7: income <= 200% FPL |
| 4 | +# Sizes 8+: income <= max(200% FPL, 60% SMI) |
| 5 | +# Note: IL IHWAP PY N uses FPL from (N-1)-01-01 and SMI from (N-1)-10-01 |
| 6 | +# period 2026 = PY2026 = FPL 2025-01-01 + SMI 2025-10-01 |
| 7 | + |
| 8 | +- name: Case 1, single person below 200% FPL is eligible. |
| 9 | + period: 2026 |
| 10 | + input: |
| 11 | + state_code: IL |
| 12 | + spm_unit_size: 1 |
| 13 | + irs_gross_income: 25_000 |
| 14 | + # PY2026 threshold for 1 person (size <= 7, FPL only): |
| 15 | + # 200% FPL = $15,650 × 2 = $31,300 |
| 16 | + # $25,000 < $31,300 = eligible |
| 17 | + output: |
| 18 | + il_ihwap_hhs_smi: 66_632.8 |
| 19 | + il_ihwap_income_eligible: true |
| 20 | + |
| 21 | +- name: Case 2, single person above 200% FPL is not eligible. |
| 22 | + period: 2026 |
| 23 | + input: |
| 24 | + state_code: IL |
| 25 | + spm_unit_size: 1 |
| 26 | + irs_gross_income: 35_000 |
| 27 | + # PY2026 threshold for 1 person (size <= 7, FPL only): |
| 28 | + # 200% FPL = $31,300 |
| 29 | + # $35,000 > $31,300 = not eligible |
| 30 | + output: |
| 31 | + il_ihwap_hhs_smi: 66_632.8 |
| 32 | + il_ihwap_income_eligible: false |
| 33 | + |
| 34 | +- name: Case 3, single person at exact 200% FPL threshold is eligible. |
| 35 | + period: 2026 |
| 36 | + input: |
| 37 | + state_code: IL |
| 38 | + spm_unit_size: 1 |
| 39 | + irs_gross_income: 31_300 |
| 40 | + # 200% FPL = $31,300 |
| 41 | + # $31,300 <= $31,300 = eligible |
| 42 | + output: |
| 43 | + il_ihwap_hhs_smi: 66_632.8 |
| 44 | + il_ihwap_income_eligible: true |
| 45 | + |
| 46 | +- name: Case 4, family of 4 below threshold is eligible. |
| 47 | + period: 2026 |
| 48 | + input: |
| 49 | + state_code: IL |
| 50 | + spm_unit_size: 4 |
| 51 | + irs_gross_income: 50_000 |
| 52 | + # PY2026 threshold for 4 people (size <= 7, FPL only): |
| 53 | + # 200% FPL = $32,150 × 2 = $64,300 |
| 54 | + # $50,000 < $64,300 = eligible |
| 55 | + output: |
| 56 | + il_ihwap_hhs_smi: 128_140 |
| 57 | + il_ihwap_income_eligible: true |
| 58 | + |
| 59 | +- name: Case 5, family of 4 above 200% FPL is not eligible. |
| 60 | + period: 2026 |
| 61 | + input: |
| 62 | + state_code: IL |
| 63 | + spm_unit_size: 4 |
| 64 | + irs_gross_income: 70_000 |
| 65 | + # PY2026 threshold for 4 people (size <= 7, FPL only): |
| 66 | + # 200% FPL = $64,300 |
| 67 | + # $70,000 > $64,300 = not eligible |
| 68 | + output: |
| 69 | + il_ihwap_hhs_smi: 128_140 |
| 70 | + il_ihwap_income_eligible: false |
| 71 | + |
| 72 | +- name: Case 6, family of 4 at exact 200% FPL threshold is eligible. |
| 73 | + period: 2026 |
| 74 | + input: |
| 75 | + state_code: IL |
| 76 | + spm_unit_size: 4 |
| 77 | + irs_gross_income: 64_300 |
| 78 | + # PY2026 threshold for 4 people: |
| 79 | + # 200% FPL = $64,300 |
| 80 | + # $64,300 <= $64,300 = eligible |
| 81 | + output: |
| 82 | + il_ihwap_hhs_smi: 128_140 |
| 83 | + il_ihwap_income_eligible: true |
| 84 | + |
| 85 | +- name: Case 7, zero income is eligible. |
| 86 | + period: 2026 |
| 87 | + input: |
| 88 | + state_code: IL |
| 89 | + spm_unit_size: 1 |
| 90 | + irs_gross_income: 0 |
| 91 | + output: |
| 92 | + il_ihwap_hhs_smi: 66_632.8 |
| 93 | + il_ihwap_income_eligible: true |
| 94 | + |
| 95 | +- name: Case 8, large family of 8 below threshold is eligible. |
| 96 | + period: 2026 |
| 97 | + input: |
| 98 | + state_code: IL |
| 99 | + spm_unit_size: 8 |
| 100 | + irs_gross_income: 70_000 |
| 101 | + # PY2026 thresholds for 8 people (size > 7, uses max): |
| 102 | + # 200% FPL = $54,150 × 2 = $108,300 |
| 103 | + # 60% SMI = $176,833 × 0.6 = $106,100 |
| 104 | + # Limit = max($108,300, $106,100) = $108,300 |
| 105 | + # $70,000 < $108,300 = eligible |
| 106 | + output: |
| 107 | + il_ihwap_hhs_smi: 176_833.2 |
| 108 | + il_ihwap_income_eligible: true |
| 109 | + |
| 110 | +- name: Case 9, large family of 8 above threshold is not eligible. |
| 111 | + period: 2026 |
| 112 | + input: |
| 113 | + state_code: IL |
| 114 | + spm_unit_size: 8 |
| 115 | + irs_gross_income: 115_000 |
| 116 | + # PY2026 threshold for 8 people: |
| 117 | + # Limit = max($108,300, $106,100) = $108,300 |
| 118 | + # $115,000 > $108,300 = not eligible |
| 119 | + output: |
| 120 | + il_ihwap_hhs_smi: 176_833.2 |
| 121 | + il_ihwap_income_eligible: false |
| 122 | + |
| 123 | +- name: Case 10, family of 7 uses FPL only threshold. |
| 124 | + period: 2026 |
| 125 | + input: |
| 126 | + state_code: IL |
| 127 | + spm_unit_size: 7 |
| 128 | + irs_gross_income: 90_000 |
| 129 | + # PY2026 threshold for 7 people (size <= 7, FPL only): |
| 130 | + # 200% FPL = $48,650 × 2 = $97,300 |
| 131 | + # $90,000 < $97,300 = eligible |
| 132 | + output: |
| 133 | + il_ihwap_hhs_smi: 172_989 |
| 134 | + il_ihwap_income_eligible: true |
| 135 | + |
| 136 | +- name: Case 11, family of 7 above FPL threshold is not eligible. |
| 137 | + period: 2026 |
| 138 | + input: |
| 139 | + state_code: IL |
| 140 | + spm_unit_size: 7 |
| 141 | + irs_gross_income: 105_000 |
| 142 | + # PY2026 threshold for 7 people (size <= 7, FPL only): |
| 143 | + # 200% FPL = $97,300 |
| 144 | + # $105,000 > $97,300 = not eligible |
| 145 | + output: |
| 146 | + il_ihwap_hhs_smi: 172_989 |
| 147 | + il_ihwap_income_eligible: false |
0 commit comments