From dbb2649437a3f720b894e582343d5d867c50550f Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Mon, 23 Mar 2026 15:02:41 -0700 Subject: [PATCH 1/7] Made small changes to test. --- programs/programs/federal/pe/tax.py | 1 + .../policyengine/calculators/dependencies/household.py | 7 +++++++ 2 files changed, 8 insertions(+) diff --git a/programs/programs/federal/pe/tax.py b/programs/programs/federal/pe/tax.py index ef9c5de81..081f3b0f6 100644 --- a/programs/programs/federal/pe/tax.py +++ b/programs/programs/federal/pe/tax.py @@ -35,6 +35,7 @@ class Aca(PolicyEngineTaxUnitCalulator): dependency.member.AgeDependency, dependency.member.IsDisabledDependency, dependency.household.ZipCodeDependency, + # dependency.household.CountyFipsDependency, *dependency.irs_gross_income, ] pe_outputs = [dependency.tax.Aca] diff --git a/programs/programs/policyengine/calculators/dependencies/household.py b/programs/programs/policyengine/calculators/dependencies/household.py index f7a3fd090..af2118b2d 100644 --- a/programs/programs/policyengine/calculators/dependencies/household.py +++ b/programs/programs/policyengine/calculators/dependencies/household.py @@ -77,9 +77,16 @@ class ZipCodeDependency(Household): dependencies = ["zipcode"] def value(self): + print("screen value:", self.screen.zipcode) return self.screen.zipcode +class CountyFipsDependency(Household): + field = "county_fips" + dependencies = ["county_fips"] + def value(self): + return "48113" + class IsInPublicHousingDependency(Household): field = "is_in_public_housing" From cf9f7de4bfec4c3544ae9c8664c961a2eca05ef8 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Wed, 25 Mar 2026 16:36:05 -0700 Subject: [PATCH 2/7] MFB-771: Add tx_aca_ptc import validations and correct initial expected values for aca_ptc --- .../calculators/dependencies/household.py | 7 - .../import_validations/data/tx_aca_ptc.json | 127 ++++++++++++++++++ .../data/260325_MFB771_tx_aca_ptc_fix.json | 26 ++++ 3 files changed, 153 insertions(+), 7 deletions(-) create mode 100644 validations/management/commands/import_validations/data/tx_aca_ptc.json create mode 100644 validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json diff --git a/programs/programs/policyengine/calculators/dependencies/household.py b/programs/programs/policyengine/calculators/dependencies/household.py index af2118b2d..f7a3fd090 100644 --- a/programs/programs/policyengine/calculators/dependencies/household.py +++ b/programs/programs/policyengine/calculators/dependencies/household.py @@ -77,16 +77,9 @@ class ZipCodeDependency(Household): dependencies = ["zipcode"] def value(self): - print("screen value:", self.screen.zipcode) return self.screen.zipcode -class CountyFipsDependency(Household): - field = "county_fips" - dependencies = ["county_fips"] - def value(self): - return "48113" - class IsInPublicHousingDependency(Household): field = "is_in_public_housing" diff --git a/validations/management/commands/import_validations/data/tx_aca_ptc.json b/validations/management/commands/import_validations/data/tx_aca_ptc.json new file mode 100644 index 000000000..e6129d564 --- /dev/null +++ b/validations/management/commands/import_validations/data/tx_aca_ptc.json @@ -0,0 +1,127 @@ +[ + { + "notes": "TX ACA PTC - Eligible single adult with no insurance and income within 100-400% FPL", + "household": { + "white_label": "tx", + "is_test": true, + "agree_to_tos": true, + "is_13_or_older": true, + "zipcode": "75001", + "county": "Dallas", + "household_size": 1, + "household_assets": 0.0, + "household_members": [ + { + "relationship": "headOfHousehold", + "age": 36, + "has_income": true, + "income_streams": [ + { + "type": "wages", + "amount": 3037.50, + "frequency": "monthly" + } + ], + "insurance": { "none": true } + } + ], + "expenses": [] + }, + "expected_results": { + "program_name": "tx_aca_ptc", + "eligible": true, + "value": 1512 + } + }, + { + "notes": "TX ACA PTC - Eligible household of 3, head on Medicaid, uninsured children, income ~200% FPL", + "household": { + "white_label": "tx", + "is_test": true, + "agree_to_tos": true, + "is_13_or_older": true, + "zipcode": "75001", + "county": "Dallas", + "household_size": 3, + "household_assets": 0.0, + "household_members": [ + { + "relationship": "headOfHousehold", + "age": 36, + "has_income": true, + "income_streams": [ + { + "type": "wages", + "amount": 4166.66, + "frequency": "monthly" + } + ], + "insurance": { + "none": false, + "medicaid": true + } + }, + { + "relationship": "child", + "age": 6, + "student": false, + "has_income": false, + "income_streams": [], + "insurance": { + "none": true + } + } + { + "relationship": "child", + "age": 2, + "student": false, + "has_income": false, + "income_streams": [], + "insurance": { + "none": true + } + } + ], + "expenses": [] + }, + "expected_results": { + "program_name": "tx_aca_ptc", + "eligible": true, + "value": 5001 + } + }, + { + "notes": "TX ACA PTC - Eligible single adult with no insurance, income ~133% FPL", + "household": { + "white_label": "tx", + "is_test": true, + "agree_to_tos": true, + "is_13_or_older": true, + "zipcode": "75001", + "county": "Dallas", + "household_size": 1, + "household_assets": 0.0, + "household_members": [ + { + "relationship": "headOfHousehold", + "age": 36, + "has_income": true, + "income_streams": [ + { + "type": "wages", + "amount": 1666.66, + "frequency": "monthly" + } + ], + "insurance": { "none": true } + } + ], + "expenses": [] + }, + "expected_results": { + "program_name": "tx_aca_ptc", + "eligible": true, + "value": 7567 + } + } +] diff --git a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json new file mode 100644 index 000000000..ed367be37 --- /dev/null +++ b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json @@ -0,0 +1,26 @@ +{ + "description": "Fix incorrect expected values for TX ACA PTC validation", + "updates": [ + { + "screen_uuid": "d68512f3-694c-4f5b-9adb-cde787959033", + "program_name": "aca_ptc", + "eligible": true, + "value": 5153, + "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + }, + { + "screen_uuid": "b88a5e3b-bf5c-49f8-9fa3-1c817a2e442b", + "program_name": "aca_ptc", + "eligible": true, + "value": 5001, + "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + }, + { + "screen_uuid": "a408c084-942b-4f86-8e68-99ed2472f0c73", + "program_name": "aca_ptc", + "eligible": true, + "value": 7567, + "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + } + ] +} From ac54e042ae015f588be28ebb9124892d2419bd58 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Wed, 25 Mar 2026 17:06:21 -0700 Subject: [PATCH 3/7] Fixed invalid UUID with correct UUID format. --- .../update_validations/data/260325_MFB771_tx_aca_ptc_fix.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json index ed367be37..fc3e656ee 100644 --- a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json +++ b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json @@ -16,7 +16,7 @@ "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." }, { - "screen_uuid": "a408c084-942b-4f86-8e68-99ed2472f0c73", + "screen_uuid": "a408c084-942b-4f86-8e68-99ed2472f0c7", "program_name": "aca_ptc", "eligible": true, "value": 7567, @@ -24,3 +24,4 @@ } ] } + From 7adf925b133f0bc70056c2a403f6f0cf43687c30 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Wed, 25 Mar 2026 17:41:52 -0700 Subject: [PATCH 4/7] MFB-771: Fix program name from aca_ptc to tx_aca in TX ACA PTC validation files --- .../commands/import_validations/data/tx_aca_ptc.json | 8 ++++---- .../data/260325_MFB771_tx_aca_ptc_fix.json | 12 ++++++------ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/validations/management/commands/import_validations/data/tx_aca_ptc.json b/validations/management/commands/import_validations/data/tx_aca_ptc.json index e6129d564..67ca00e8e 100644 --- a/validations/management/commands/import_validations/data/tx_aca_ptc.json +++ b/validations/management/commands/import_validations/data/tx_aca_ptc.json @@ -28,7 +28,7 @@ "expenses": [] }, "expected_results": { - "program_name": "tx_aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 1512 } @@ -70,7 +70,7 @@ "insurance": { "none": true } - } + }, { "relationship": "child", "age": 2, @@ -85,7 +85,7 @@ "expenses": [] }, "expected_results": { - "program_name": "tx_aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 5001 } @@ -119,7 +119,7 @@ "expenses": [] }, "expected_results": { - "program_name": "tx_aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 7567 } diff --git a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json index fc3e656ee..20cdc8f65 100644 --- a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json +++ b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json @@ -3,24 +3,24 @@ "updates": [ { "screen_uuid": "d68512f3-694c-4f5b-9adb-cde787959033", - "program_name": "aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 5153, - "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + "reason": "MFB-771: Initial expected value for tx_aca was incorrect at the time the validation was created." }, { "screen_uuid": "b88a5e3b-bf5c-49f8-9fa3-1c817a2e442b", - "program_name": "aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 5001, - "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + "reason": "MFB-771: Initial expected value for tx_aca was incorrect at the time the validation was created." }, { "screen_uuid": "a408c084-942b-4f86-8e68-99ed2472f0c7", - "program_name": "aca_ptc", + "program_name": "tx_aca", "eligible": true, "value": 7567, - "reason": "MFB-771: Initial expected value for aca_ptc was incorrect at the time the validation was created." + "reason": "MFB-771: Initial expected value for tx_aca was incorrect at the time the validation was created." } ] } From 0707413a0505fbb10e57432186f3a4a74afc53f6 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Thu, 26 Mar 2026 10:28:07 -0700 Subject: [PATCH 5/7] Fixed failing validation by fixing result value. --- .../commands/import_validations/data/tx_aca_ptc.json | 4 ++-- .../update_validations/data/260325_MFB771_tx_aca_ptc_fix.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/validations/management/commands/import_validations/data/tx_aca_ptc.json b/validations/management/commands/import_validations/data/tx_aca_ptc.json index 67ca00e8e..558a3d4fc 100644 --- a/validations/management/commands/import_validations/data/tx_aca_ptc.json +++ b/validations/management/commands/import_validations/data/tx_aca_ptc.json @@ -30,7 +30,7 @@ "expected_results": { "program_name": "tx_aca", "eligible": true, - "value": 1512 + "value": 5152 } }, { @@ -87,7 +87,7 @@ "expected_results": { "program_name": "tx_aca", "eligible": true, - "value": 5001 + "value": 5000 } }, { diff --git a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json index 20cdc8f65..f08ed8e09 100644 --- a/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json +++ b/validations/management/commands/update_validations/data/260325_MFB771_tx_aca_ptc_fix.json @@ -12,7 +12,7 @@ "screen_uuid": "b88a5e3b-bf5c-49f8-9fa3-1c817a2e442b", "program_name": "tx_aca", "eligible": true, - "value": 5001, + "value": 5000, "reason": "MFB-771: Initial expected value for tx_aca was incorrect at the time the validation was created." }, { From 24bbde58482dcba5a70160999326deca57334c02 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Thu, 26 Mar 2026 11:19:43 -0700 Subject: [PATCH 6/7] Made small change. --- programs/programs/federal/pe/tax.py | 1 - 1 file changed, 1 deletion(-) diff --git a/programs/programs/federal/pe/tax.py b/programs/programs/federal/pe/tax.py index 081f3b0f6..ef9c5de81 100644 --- a/programs/programs/federal/pe/tax.py +++ b/programs/programs/federal/pe/tax.py @@ -35,7 +35,6 @@ class Aca(PolicyEngineTaxUnitCalulator): dependency.member.AgeDependency, dependency.member.IsDisabledDependency, dependency.household.ZipCodeDependency, - # dependency.household.CountyFipsDependency, *dependency.irs_gross_income, ] pe_outputs = [dependency.tax.Aca] From a1b5f535f54447b054657501ae1f516d979dede3 Mon Sep 17 00:00:00 2001 From: SonaliBedge Date: Thu, 26 Mar 2026 15:51:48 -0700 Subject: [PATCH 7/7] Deleted update validation file and added ineligible test scenario to tx_aca_ptc.json file. --- .../import_validations/data/tx_aca_ptc.json | 39 ++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/validations/management/commands/import_validations/data/tx_aca_ptc.json b/validations/management/commands/import_validations/data/tx_aca_ptc.json index 558a3d4fc..7b2d152ab 100644 --- a/validations/management/commands/import_validations/data/tx_aca_ptc.json +++ b/validations/management/commands/import_validations/data/tx_aca_ptc.json @@ -123,5 +123,42 @@ "eligible": true, "value": 7567 } - } + }, + { + "notes": "TX ACA PTC - Ineligible single adult enrolled in Medicare", + "household": { + "white_label": "tx", + "is_test": true, + "agree_to_tos": true, + "is_13_or_older": true, + "zipcode": "75001", + "county": "Dallas", + "household_size": 1, + "household_assets": 0.0, + "household_members": [ + { + "relationship": "headOfHousehold", + "age": 67, + "has_income": true, + "income_streams": [ + { + "type": "wages", + "amount": 1666.66, + "frequency": "monthly" + } + ], + "insurance": { + "none": false, + "medicare": true + } + } + ], + "expenses": [] + }, + "expected_results": { + "program_name": "tx_aca", + "eligible": false, + "value": 0 + } + } ]