Skip to content

Commit cf43372

Browse files
authored
Add tests for abolishing parameters (#1148)
* add tests * changelog
1 parent 2c4d5e9 commit cf43372

2 files changed

Lines changed: 254 additions & 0 deletions

File tree

changelog_entry.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- bump: patch
2+
changes:
3+
added:
4+
- Add test suite for abolition parameters functionality.
Lines changed: 250 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,250 @@
1+
- name: Child benefit abolition test
2+
period: 2025
3+
input:
4+
gov.abolitions.child_benefit: true
5+
people:
6+
parent:
7+
age: 35
8+
child:
9+
age: 5
10+
benunits:
11+
benunit:
12+
members: [parent, child]
13+
would_claim_child_benefit: true
14+
output:
15+
child_benefit: [0, 0]
16+
17+
- name: State pension abolition test
18+
period: 2025
19+
input:
20+
gov.abolitions.state_pension: true
21+
people:
22+
pensioner:
23+
age: 67
24+
state_pension_age: 67
25+
output:
26+
state_pension: 0
27+
28+
- name: Employment income abolition test
29+
period: 2025
30+
input:
31+
gov.abolitions.employment_income: true
32+
people:
33+
worker:
34+
age: 30
35+
employment_income: 50000
36+
output:
37+
employment_income: 0
38+
39+
- name: Universal credit abolition test
40+
period: 2025
41+
input:
42+
gov.abolitions.universal_credit: true
43+
people:
44+
claimant:
45+
age: 25
46+
benunits:
47+
benunit:
48+
members: [claimant]
49+
would_claim_uc: true
50+
output:
51+
universal_credit: 0
52+
53+
- name: Income tax abolition test
54+
period: 2025
55+
input:
56+
gov.abolitions.income_tax: true
57+
people:
58+
taxpayer:
59+
age: 30
60+
employment_income: 50000
61+
output:
62+
income_tax: 0
63+
64+
- name: National insurance abolition test
65+
period: 2025
66+
input:
67+
gov.abolitions.national_insurance: true
68+
people:
69+
worker:
70+
age: 30
71+
employment_income: 50000
72+
output:
73+
national_insurance: 0
74+
75+
- name: Carers allowance abolition test
76+
period: 2025
77+
input:
78+
gov.abolitions.carers_allowance: true
79+
people:
80+
carer:
81+
age: 30
82+
care_hours: 40
83+
output:
84+
carers_allowance: 0
85+
86+
- name: Housing benefit abolition test
87+
period: 2025
88+
input:
89+
gov.abolitions.housing_benefit: true
90+
people:
91+
claimant:
92+
age: 25
93+
benunits:
94+
benunit:
95+
members: [claimant]
96+
households:
97+
household:
98+
members: [claimant]
99+
rent: 500
100+
BRMA: "CENTRAL_LONDON"
101+
tenure_type: "RENT_PRIVATELY"
102+
output:
103+
housing_benefit: 0
104+
105+
- name: Pension credit abolition test
106+
period: 2025
107+
input:
108+
gov.abolitions.pension_credit: true
109+
people:
110+
pensioner:
111+
age: 67
112+
state_pension_age: 67
113+
output:
114+
pension_credit: 0
115+
116+
- name: Working tax credit abolition test
117+
period: 2025
118+
input:
119+
gov.abolitions.working_tax_credit: true
120+
people:
121+
worker:
122+
age: 30
123+
employment_income: 15000
124+
weekly_hours: 35
125+
output:
126+
working_tax_credit: 0
127+
128+
- name: Child tax credit abolition test
129+
period: 2025
130+
input:
131+
gov.abolitions.child_tax_credit: true
132+
people:
133+
parent:
134+
age: 30
135+
employment_income: 15000
136+
child:
137+
age: 5
138+
benunits:
139+
benunit:
140+
members: [parent, child]
141+
output:
142+
child_tax_credit: 0
143+
144+
- name: Income support abolition test
145+
period: 2025
146+
input:
147+
gov.abolitions.income_support: true
148+
people:
149+
claimant:
150+
age: 25
151+
output:
152+
income_support: 0
153+
154+
- name: JSA income abolition test
155+
period: 2025
156+
input:
157+
gov.abolitions.jsa_income: true
158+
people:
159+
claimant:
160+
age: 25
161+
output:
162+
jsa_income: 0
163+
164+
- name: ESA income abolition test
165+
period: 2025
166+
input:
167+
gov.abolitions.esa_income: true
168+
people:
169+
claimant:
170+
age: 25
171+
output:
172+
esa_income: 0
173+
174+
- name: Attendance allowance abolition test
175+
period: 2025
176+
input:
177+
gov.abolitions.attendance_allowance: true
178+
people:
179+
claimant:
180+
age: 70
181+
aa_category: "LOWER"
182+
output:
183+
attendance_allowance: 0
184+
185+
- name: Council tax benefit abolition test
186+
period: 2025
187+
input:
188+
gov.abolitions.council_tax_benefit: true
189+
people:
190+
claimant:
191+
age: 25
192+
benunits:
193+
benunit:
194+
members: [claimant]
195+
households:
196+
household:
197+
members: [claimant]
198+
council_tax_band: "A"
199+
region: "LONDON"
200+
output:
201+
council_tax_benefit: 0
202+
203+
- name: Stamp duty land tax abolition test
204+
period: 2025
205+
input:
206+
gov.abolitions.stamp_duty_land_tax: true
207+
people:
208+
buyer:
209+
age: 30
210+
households:
211+
household:
212+
members: [buyer]
213+
main_residential_property_purchased: 300000
214+
output:
215+
stamp_duty_land_tax: 0
216+
217+
- name: VAT abolition test
218+
period: 2025
219+
input:
220+
gov.abolitions.vat: true
221+
people:
222+
consumer:
223+
age: 30
224+
households:
225+
household:
226+
members: [consumer]
227+
full_rate_vat_consumption: 1000
228+
output:
229+
vat: 0
230+
231+
- name: Capital gains tax abolition test
232+
period: 2025
233+
input:
234+
gov.abolitions.capital_gains_tax: true
235+
people:
236+
investor:
237+
age: 30
238+
capital_gains: 50000
239+
output:
240+
capital_gains_tax: 0
241+
242+
- name: Business rates abolition test
243+
period: 2025
244+
input:
245+
gov.abolitions.business_rates: true
246+
people:
247+
business_owner:
248+
age: 30
249+
output:
250+
business_rates: 0

0 commit comments

Comments
 (0)