diff --git a/l10n_us_hr_payroll/data/state/ga_georgia.xml b/l10n_us_hr_payroll/data/state/ga_georgia.xml
index 659515db..3c900ce6 100644
--- a/l10n_us_hr_payroll/data/state/ga_georgia.xml
+++ b/l10n_us_hr_payroll/data/state/ga_georgia.xml
@@ -7,11 +7,7 @@
-
- 9500.00
-
-
-
+
9500.00
@@ -26,11 +22,7 @@
-
- 2.7
-
-
-
+
2.7
@@ -44,304 +36,9 @@
-
- {
- 'married filing joint, both spouses working': {
- 'weekly': (
- ( 9.50, 0.00, 1.00),
- (29.00, 0.10, 2.00),
- (48.00, 0.48, 3.00),
- (67.50, 1.06, 4.00),
- (96.00, 1.83, 5.00),
- ('inf', 3.27, 5.75),
- ),
- 'bi-weekly': (
- ( 19.00, 0.00, 1.00),
- ( 57.50, 0.19, 2.00),
- ( 96.00, 0.96, 3.00),
- (135.00, 2.12, 4.00),
- (192.00, 3.65, 5.00),
- ( 'inf', 6.54, 5.75),
- ),
- 'semi-monthly': (
- ( 21.00, 0.00, 1.00),
- ( 62.50, 0.21, 2.00),
- (104.00, 1.04, 3.00),
- (146.00, 2.29, 4.00),
- (208.00, 3.96, 5.00),
- ( 'inf', 7.08, 5.75),
- ),
- 'monthly': (
- ( 41.50, 0.00, 1.00),
- (125.50, 0.42, 2.00),
- (208.00, 2.08, 3.00),
- (292.00, 4.58, 4.00),
- (417.00, 7.92, 5.00),
- ( 'inf', 14.17, 5.75),
- ),
- 'quarterly': (
- ( 125.00, 0.00, 1.00),
- ( 375.00, 1.25, 2.00),
- ( 625.00, 6.25, 3.00),
- ( 875.00, 13.75, 4.00),
- (1250.00, 23.75, 5.00),
- ( 'inf', 42.50, 5.75),
- ),
- 'semi-annual': (
- ( 250.00, 0.00, 1.00),
- ( 750.00, 2.50, 2.00),
- (1250.00, 12.50, 3.00),
- (1750.00, 27.50, 4.00),
- (2500.00, 47.50, 5.00),
- ( 'inf', 85.00, 5.75),
- ),
- 'annual': (
- ( 500.00, 0.00, 1.00),
- (1500.00, 5.00, 2.00),
- (2500.00, 25.00, 3.00),
- (3500.00, 55.00, 4.00),
- (5000.00, 95.00, 5.00),
- ( 'inf', 170.00, 5.75),
- ),
- },
- 'married filing joint, one spouse working': {
- 'weekly': (
- ( 19.00, 0.00, 1.00),
- ( 57.50, 0.19, 2.00),
- ( 96.00, 0.96, 3.00),
- (135.00, 2.12, 4.00),
- (192.50, 3.65, 5.00),
- ( 'inf', 6.54, 5.75),
- ),
- 'bi-weekly': (
- ( 38.50, 0.00, 1.00),
- (115.00, 0.38, 2.00),
- (192.00, 1.92, 3.00),
- (269.00, 4.23, 4.00),
- (385.00, 7.31, 5.00),
- ( 'inf', 13.08, 5.75),
- ),
- 'semi-monthly': (
- ( 41.50, 0.00, 1.00),
- (125.00, 0.42, 2.00),
- (208.00, 2.08, 3.00),
- (292.00, 4.58, 4.00),
- (417.00, 7.92, 5.00),
- ( 'inf', 14.17, 5.75),
- ),
- 'monthly': (
- ( 83.00, 0.00, 1.00),
- (250.00, 0.83, 2.00),
- (417.00, 4.17, 3.00),
- (583.00, 9.17, 4.00),
- (833.00, 15.83, 5.00),
- ( 'inf', 28.33, 5.75),
- ),
- 'quarterly': (
- ( 250.00, 0.00, 1.00),
- ( 750.00, 2.50, 2.00),
- (1250.00, 12.50, 3.00),
- (1750.00, 27.50, 4.00),
- (2500.00, 47.50, 5.00),
- ( 'inf', 85.00, 5.75),
- ),
- 'semi-annual': (
- ( 500.00, 0.00, 1.00),
- (1500.00, 5.00, 2.00),
- (2500.00, 25.00, 3.00),
- (3500.00, 55.00, 4.00),
- (5000.00, 95.00, 5.00),
- ( 'inf', 170.00, 5.75),
- ),
- 'annual': (
- ( 1000.00, 0.00, 1.00),
- ( 3000.00, 10.00, 2.00),
- ( 5000.00, 50.00, 3.00),
- ( 7000.00, 110.00, 4.00),
- (10000.00, 190.00, 5.00),
- ( 'inf', 340.00, 5.75),
- ),
- },
- 'single': {
- 'weekly': (
- ( 14.50, 0.00, 1.00),
- ( 43.50, 0.14, 2.00),
- ( 72.00, 0.72, 3.00),
- (101.00, 1.59, 4.00),
- (135.00, 2.74, 5.00),
- ( 'inf', 4.42, 5.75),
- ),
- 'bi-weekly': (
- ( 29.00, 0.00, 1.00),
- ( 86.50, 0.29, 2.00),
- (144.00, 1.44, 3.00),
- (202.00, 3.17, 4.00),
- (269.00, 5.48, 5.00),
- ( 'inf', 8.85, 5.75),
- ),
- 'semi-monthly': (
- ( 31.00, 0.00, 1.00),
- ( 93.50, 0.31, 2.00),
- (156.00, 1.56, 3.00),
- (219.00, 3.34, 4.00),
- (292.00, 5.94, 5.00),
- ( 'inf', 9.58, 5.75),
- ),
- 'monthly': (
- ( 62.50, 0.00, 1.00),
- (187.00, 0.62, 2.00),
- (312.00, 3.12, 3.00),
- (437.00, 6.87, 4.00),
- (583.00, 11.87, 5.00),
- ( 'inf', 19.17, 5.75),
- ),
- 'quarterly': (
- ( 187.50, 0.00, 1.00),
- ( 562.50, 1.88, 2.00),
- ( 937.50, 9.38, 3.00),
- (1312.00, 20.63, 4.00),
- (1750.00, 35.63, 5.00),
- ( 'inf', 57.50, 5.75),
- ),
- 'semi-annual': (
- ( 375.00, 0.00, 1.00),
- (1125.00, 3.75, 2.00),
- (1875.00, 18.75, 3.00),
- (2625.00, 41.25, 4.00),
- (3500.00, 71.25, 5.00),
- ( 'inf', 115.00, 5.75),
- ),
- 'annual': (
- ( 750.00, 0.00, 1.00),
- (2250.00, 7.50, 2.00),
- (3750.00, 37.50, 3.00),
- (5250.00, 82.50, 4.00),
- (7000.00, 142.50, 5.00),
- ( 'inf', 230.00, 5.75),
- ),
- },
- 'head of household': {
- 'weekly': (
- ( 19.00, 0.00, 1.00),
- ( 57.50, 0.19, 2.00),
- ( 96.00, 0.96, 3.00),
- (135.00, 2.12, 4.00),
- (192.50, 3.65, 5.00),
- ( 'inf', 6.54, 5.75),
- ),
- 'bi-weekly': (
- ( 38.50, 0.00, 1.00),
- (115.00, 0.38, 2.00),
- (192.00, 1.92, 3.00),
- (269.00, 4.23, 4.00),
- (385.00, 7.31, 5.00),
- ( 'inf', 13.08, 5.75),
- ),
- 'semi-monthly': (
- ( 41.50, 0.00, 1.00),
- (125.00, 0.42, 2.00),
- (208.00, 2.08, 3.00),
- (292.00, 4.58, 4.00),
- (417.00, 7.92, 5.00),
- ( 'inf', 14.17, 5.75),
- ),
- 'monthly': (
- ( 83.00, 0.00, 1.00),
- (250.00, 0.83, 2.00),
- (417.00, 4.17, 3.00),
- (583.00, 9.17, 4.00),
- (833.00, 15.83, 5.00),
- ( 'inf', 28.33, 5.75),
- ),
- 'quarterly': (
- ( 250.00, 0.00, 1.00),
- ( 750.00, 2.50, 2.00),
- (1250.00, 12.50, 3.00),
- (1750.00, 27.50, 4.00),
- (2500.00, 47.50, 5.00),
- ( 'inf', 85.00, 5.75),
- ),
- 'semi-annual': (
- ( 500.00, 0.00, 1.00),
- (1500.00, 5.00, 2.00),
- (2500.00, 25.00, 3.00),
- (3500.00, 55.00, 4.00),
- (5000.00, 95.00, 5.00),
- ( 'inf', 170.00, 5.75),
- ),
- 'annual': (
- ( 1000.00, 0.00, 1.00),
- ( 3000.00, 10.00, 2.00),
- ( 5000.00, 50.00, 3.00),
- ( 7000.00, 110.00, 4.00),
- (10000.00, 190.00, 5.00),
- ( 'inf', 340.00, 5.75),
- ),
- },
- 'married filing separate': {
- 'weekly': (
- ( 9.50, 0.00, 1.00),
- (29.00, 0.10, 2.00),
- (48.00, 0.48, 3.00),
- (67.50, 1.06, 4.00),
- (96.00, 1.83, 5.00),
- ('inf', 3.27, 5.75),
- ),
- 'bi-weekly': (
- ( 19.00, 0.00, 1.00),
- ( 57.50, 0.19, 2.00),
- ( 96.00, 0.96, 3.00),
- (135.00, 2.12, 4.00),
- (192.00, 3.65, 5.00),
- ( 'inf', 6.54, 5.75),
- ),
- 'semi-monthly': (
- ( 21.00, 0.00, 1.00),
- ( 62.50, 0.21, 2.00),
- (104.00, 1.04, 3.00),
- (146.00, 2.29, 4.00),
- (208.00, 3.96, 5.00),
- ( 'inf', 7.08, 5.75),
- ),
- 'monthly': (
- ( 41.50, 0.00, 1.00),
- (125.50, 0.42, 2.00),
- (208.00, 2.08, 3.00),
- (292.00, 4.58, 4.00),
- (417.00, 7.92, 5.00),
- ( 'inf', 14.17, 5.75),
- ),
- 'quarterly': (
- ( 125.00, 0.00, 1.00),
- ( 375.00, 1.25, 2.00),
- ( 625.00, 6.25, 3.00),
- ( 875.00, 13.75, 4.00),
- (1250.00, 23.75, 5.00),
- ( 'inf', 42.50, 5.75),
- ),
- 'semi-annual': (
- ( 250.00, 0.00, 1.00),
- ( 750.00, 2.50, 2.00),
- (1250.00, 12.50, 3.00),
- (1750.00, 27.50, 4.00),
- (2500.00, 47.50, 5.00),
- ( 'inf', 85.00, 5.75),
- ),
- 'annual': (
- ( 500.00, 0.00, 1.00),
- (1500.00, 5.00, 2.00),
- (2500.00, 25.00, 3.00),
- (3500.00, 55.00, 4.00),
- (5000.00, 95.00, 5.00),
- ( 'inf', 170.00, 5.75),
- ),
- },
- }
-
-
-
+
{
'married filing joint, both spouses working': {
@@ -646,59 +343,9 @@
-
- {
- 'married filing joint, both spouses working': {
- 'weekly': 142.30,
- 'bi-weekly': 284.62,
- 'semi-monthly': 308.33,
- 'monthly': 616.67,
- 'quarterly': 1850.00,
- 'semi-annual': 3700.00,
- 'annual': 7400.00,
- },
- 'married filing joint, one spouse working': {
- 'weekly': 142.30,
- 'bi-weekly': 284.62,
- 'semi-monthly': 308.33,
- 'monthly': 616.67,
- 'quarterly': 1850.00,
- 'semi-annual': 3700.00,
- 'annual': 7400.00,
- },
- 'single': {
- 'weekly': 51.92,
- 'bi-weekly': 103.85,
- 'semi-monthly': 112.50,
- 'monthly': 225.00,
- 'quarterly': 675.00,
- 'semi-annual': 1350.00,
- 'annual': 2700.00,
- },
- 'head of household': {
- 'weekly': 51.92,
- 'bi-weekly': 103.85,
- 'semi-monthly': 112.50,
- 'monthly': 225.00,
- 'quarterly': 675.00,
- 'semi-annual': 1350.00,
- 'annual': 2700.00,
- },
- 'married filing separate': {
- 'weekly': 71.15,
- 'bi-weekly': 142.30,
- 'semi-monthly': 154.16,
- 'monthly': 308.33,
- 'quarterly': 925.00,
- 'semi-annual': 1850.00,
- 'annual': 3700.00,
- },
- }
-
-
-
+
{
'married filing joint, both spouses working': {
@@ -758,21 +405,9 @@
-
- {
- 'weekly': 57.50,
- 'bi-weekly': 115.00,
- 'semi-monthly': 125.00,
- 'monthly': 250.00,
- 'quarterly': 750.00,
- 'semi-annual': 1500.00,
- 'annual': 3000.00,
- }
-
-
-
+
{
'weekly': 57.50,
@@ -794,59 +429,9 @@
-
- {
- 'married filing joint, both spouses working': {
- 'weekly': 115.50,
- 'bi-weekly': 230.75,
- 'semi-monthly': 250.00,
- 'monthly': 500.00,
- 'quarterly': 1500.00,
- 'semi-annual': 3000.00,
- 'annual': 6000.00,
- },
- 'married filing joint, one spouse working': {
- 'weekly': 115.50,
- 'bi-weekly': 230.75,
- 'semi-monthly': 250.00,
- 'monthly': 500.00,
- 'quarterly': 1500.00,
- 'semi-annual': 3000.00,
- 'annual': 6000.00,
- },
- 'single': {
- 'weekly': 88.50,
- 'bi-weekly': 177.00,
- 'semi-monthly': 191.75,
- 'monthly': 383.50,
- 'quarterly': 1150.00,
- 'semi-annual': 2300.00,
- 'annual': 4600.00,
- },
- 'head of household': {
- 'weekly': 88.50,
- 'bi-weekly': 177.00,
- 'semi-monthly': 191.75,
- 'monthly': 383.50,
- 'quarterly': 1150.00,
- 'semi-annual': 2300.00,
- 'annual': 4600.00,
- },
- 'married filing separate': {
- 'weekly': 57.75,
- 'bi-weekly': 115.50,
- 'semi-monthly': 125.00,
- 'monthly': 250.00,
- 'quarterly': 750.00,
- 'semi-annual': 1500.00,
- 'annual': 3000.00,
- },
- }
-
-
-
+
{
'married filing joint, both spouses working': {
diff --git a/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2019.py b/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2019.py
deleted file mode 100755
index 98206965..00000000
--- a/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2019.py
+++ /dev/null
@@ -1,135 +0,0 @@
-# Part of Hibou Suite Professional. See LICENSE_PROFESSIONAL file for full copyright and licensing details.
-
-from .common import TestUsPayslip, process_payslip
-
-
-class TestUsGAPayslip(TestUsPayslip):
-
- # TAXES AND RATES
- GA_UNEMP_MAX_WAGE = 9500.00
- GA_UNEMP = -(2.70 / 100.0)
-
- def test_taxes_weekly_single_with_additional_wh(self):
- salary = 15000.00
- schedule_pay = 'weekly'
- allowances = 1
- filing_status = 'single'
- additional_wh = 12.50
- # Hand Calculated Amount to Test
- # Step 1 - Subtract standard deduction from wages. Std Deduct for single weekly is 88.50
- # step1 = 15000.00 - 88.50 = 14911.5
- # Step 2 - Subtract personal allowance from step1. Allowance for single weekly is 51.92
- # step2 = step1 - 51.92 = 14859.58
- # Step 3 - Subtract amount for dependents. Weekly dependent allowance is 57.50
- # step3 = 14859.58 - 57.50 = 14802.08
- # Step 4 -Determine wh amount from tables
- # step4 = 4.42 + ((5.75 / 100.00) * (14802.08 - 135.00))
- # Add additional_wh
- # wh = 847.7771 + 12.50 = 860.2771
- wh = -860.28
-
- employee = self._createEmployee()
- contract = self._createContract(employee,
- wage=salary,
- state_id=self.get_us_state('GA'),
- ga_g4_sit_dependent_allowances=allowances,
- ga_g4_sit_additional_allowances=0,
- ga_g4_sit_filing_status=filing_status,
- state_income_tax_additional_withholding=additional_wh,
- schedule_pay=schedule_pay)
-
- self.assertEqual(contract.schedule_pay, 'weekly')
-
- self._log('2019 Georgia tax first payslip weekly:')
- payslip = self._createPayslip(employee, '2019-01-01', '2019-01-31')
- payslip.compute_sheet()
- cats = self._getCategories(payslip)
-
- self.assertPayrollEqual(cats['ER_US_SUTA'], self.GA_UNEMP_MAX_WAGE * self.GA_UNEMP)
- self.assertPayrollEqual(cats['EE_US_SIT'], wh)
-
- process_payslip(payslip)
-
- remaining_GA_UNEMP_wages = 0.0 # We already reached max unemployment wages.
-
- self._log('2019 Georgia tax second payslip weekly:')
- payslip = self._createPayslip(employee, '2019-02-01', '2019-02-28')
- payslip.compute_sheet()
- cats = self._getCategories(payslip)
-
- self.assertPayrollEqual(cats['ER_US_SUTA'], remaining_GA_UNEMP_wages * self.GA_UNEMP)
-
-
- def test_taxes_monthly_head_of_household(self):
- salary = 25000.00
- schedule_pay = 'monthly'
- allowances = 2
- filing_status = 'head of household'
- additional_wh = 15.00
- # Hand Calculated Amount to Test
- # Step 1 - Subtract standard deduction from wages. Std Deduct for head of household monthly is 383.50
- # step1 = 25000.00 - 383.50 = 24616.5
- # Step 2 - Subtract personal allowance from step1. Allowance for head of household monthly is 225.00
- # step2 = 24616.5 - 225.00 = 24391.5
- # Step 3 - Subtract amount for dependents. Weekly dependent allowance is 250.00
- # step3 = 24391.5 - (2 * 250.00) = 23891.5
- # Step 4 - Determine wh amount from tables
- # step4 = 28.33 + ((5.75 / 100.00) * (23891.5 - 833.00)) = 1354.19375
- # Add additional_wh
- # wh = 1354.19375 + 15.00 = 1369.19375
- wh = -1369.19
-
- employee = self._createEmployee()
- contract = self._createContract(employee,
- wage=salary,
- state_id=self.get_us_state('GA'),
- ga_g4_sit_dependent_allowances=allowances,
- ga_g4_sit_additional_allowances=0,
- ga_g4_sit_filing_status=filing_status,
- state_income_tax_additional_withholding=additional_wh,
- schedule_pay=schedule_pay)
-
- self.assertEqual(contract.schedule_pay, 'monthly')
-
- self._log('2019 Georgia tax first payslip monthly:')
- payslip = self._createPayslip(employee, '2019-01-01', '2019-01-31')
- payslip.compute_sheet()
- cats = self._getCategories(payslip)
-
- self.assertPayrollEqual(cats['ER_US_SUTA'], self.GA_UNEMP_MAX_WAGE * self.GA_UNEMP)
- self.assertPayrollAlmostEqual(cats['EE_US_SIT'], wh)
-
- process_payslip(payslip)
-
- remaining_GA_UNEMP_wages = 0.0 # We already reached max unemployment wages.
-
- self._log('2019 Georgia tax second payslip weekly:')
- payslip = self._createPayslip(employee, '2019-02-01', '2019-02-28')
- payslip.compute_sheet()
- cats = self._getCategories(payslip)
-
- self.assertPayrollEqual(cats['ER_US_SUTA'], remaining_GA_UNEMP_wages * self.GA_UNEMP)
-
- def test_taxes_exempt(self):
- salary = 25000.00
- schedule_pay = 'monthly'
- allowances = 2
- filing_status = ''
- additional_wh = 15.00
-
- employee = self._createEmployee()
- contract = self._createContract(employee,
- wage=salary,
- state_id=self.get_us_state('GA'),
- ga_g4_sit_dependent_allowances=allowances,
- ga_g4_sit_additional_allowances=0,
- ga_g4_sit_filing_status=filing_status,
- state_income_tax_additional_withholding=additional_wh,
- schedule_pay=schedule_pay)
-
- self._log('2019 Georgia tax first payslip exempt:')
- payslip = self._createPayslip(employee, '2019-01-01', '2019-01-31')
- payslip.compute_sheet()
- cats = self._getCategories(payslip)
-
- self.assertPayrollEqual(cats.get('EE_US_SIT', 0), 0)
diff --git a/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2021.py b/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2021.py
new file mode 100755
index 00000000..56cb9abc
--- /dev/null
+++ b/l10n_us_hr_payroll/tests/test_us_ga_georgia_payslip_2021.py
@@ -0,0 +1,39 @@
+# Part of Hibou Suite Professional. See LICENSE_PROFESSIONAL file for full copyright and licensing details.
+
+from datetime import date, timedelta
+from .common import TestUsPayslip
+
+
+class TestUsGAPayslip(TestUsPayslip):
+
+ # TAXES AND RATES
+ GA_UNEMP_MAX_WAGE = 9500.00
+ GA_UNEMP = 2.70
+
+ # Example calculated based on https://dor.georgia.gov/employers-tax-guide 2021_employer tax gauide
+
+ def _test_sit(self, wage, filing_status, additional_withholding, dependent_allowances, additional_allowances,
+ schedule_pay, date_start, expected_withholding):
+ employee = self._createEmployee()
+ contract = self._createContract(employee,
+ wage=wage,
+ state_id=self.get_us_state('GA'),
+ ga_g4_sit_filing_status=filing_status,
+ state_income_tax_additional_withholding=additional_withholding,
+ ga_g4_sit_dependent_allowances=dependent_allowances,
+ ga_g4_sit_additional_allowances=additional_allowances,
+ schedule_pay=schedule_pay)
+ payslip = self._createPayslip(employee, date_start, date_start + timedelta(days=7))
+ payslip.compute_sheet()
+ cats = self._getCategories(payslip)
+
+ self._log('Computed period tax: ' + str(expected_withholding))
+ self.assertPayrollAlmostEqual(cats.get('EE_US_SIT', 0.0), -expected_withholding)
+
+ def test_2021_taxes_example(self):
+ self._test_er_suta('GA', self.GA_UNEMP, date(2021, 1, 1), wage_base=self.GA_UNEMP_MAX_WAGE)
+ self._test_sit(15000.0, 'single', 12.50, 1, 0, 'weekly', date(2021, 1, 1), 860.28)
+ self._test_sit(25000.0, 'head of household', 15.00, 2, 0, 'monthly', date(2021, 1, 1), 1369.19)
+ self._test_sit(425.0, 'married filing separate', 0.0, 1, 0, 'weekly', date(2021, 1, 1), 11.45)
+ self._test_sit(3000.0, 'single', 0.00, 1, 1, 'quarterly', date(2021, 1, 1), 0.0)
+ self._test_sit(2500.0, '', 0.00, 1, 1, 'quarterly', date(2021, 1, 1), 0.0)