Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/hb-nondep-history.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Added the enacted 2015 to 2017 Housing Benefit non-dependant deduction thresholds and amounts instead of backdating the 2018 scale.
Original file line number Diff line number Diff line change
Expand Up @@ -2,73 +2,253 @@ description: The following amount is provided for individuals under the Housing

brackets:
- threshold:
2015-04-01:
value: 0
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 0
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 0
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 0
amount:
2015-04-01:
value: 14.55
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 14.65
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 14.8
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 15.25
2021-04-01: 15.95
2022-04-01: 16.45
2023-04-01: 18.1
2024-04-01: 19.3
2026-04-01: 20.4
- threshold:
2015-04-01:
value: 129
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 133
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 136
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 139
2021-04-01: 154
2023-04-01: 162
2024-04-01: 176
2026-04-01: 192
amount:
2015-04-01:
value: 33.4
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 33.65
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 34
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 35
2021-04-01: 36.65
2022-04-01: 37.8
2023-04-01: 41.6
2024-04-01: 44.4
2026-04-01: 46.85
- threshold:
2015-04-01:
value: 189
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 195
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 200
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 204
2021-04-01: 224
2023-04-01: 236
2024-04-01: 256
2026-04-01: 279
amount:
2015-04-01:
value: 45.85
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 46.2
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 46.65
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 48.05
2021-04-01: 50.3
2022-04-01: 51.85
2023-04-01: 57.1
2024-04-01: 60.95
2026-04-01: 64.35
- threshold:
2015-04-01:
value: 246
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 253
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 259
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 265
2021-04-01: 292
2023-04-01: 308
2024-04-01: 334
2026-04-01: 365
amount:
2015-04-01:
value: 75.05
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 75.6
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 76.35
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 78.65
2021-04-01: 82.3
2022-04-01: 84.85
2023-04-01: 93.4
2024-04-01: 99.65
2026-04-01: 105.2
- threshold:
2015-04-01:
value: 328
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 338
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 346
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 354
2021-04-01: 389
2023-04-01: 410
2024-04-01: 445
2026-04-01: 485
amount:
2015-04-01:
value: 85.45
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 86.1
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 86.95
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 89.55
2021-04-01: 93.7
2022-04-01: 96.6
2023-04-01: 106.35
2024-04-01: 113.5
2026-04-01: 119.85
- threshold:
2015-04-01:
value: 408
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 420
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 430
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 439
2021-04-01: 484
2023-04-01: 511
2024-04-01: 554
2026-04-01: 605
amount:
2015-04-01:
value: 93.8
reference:
- title: 2015 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2015/457/article/18/made
2016-04-01:
value: 94.5
reference:
- title: 2016 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2016/242/regulation/5/made
2017-04-01:
value: 95.45
reference:
- title: 2017 Housing Benefit non-dependant deduction uprating
href: https://www.legislation.gov.uk/uksi/2017/260/article/22/made
2018-06-18: 98.3
2021-04-01: 102.85
2022-04-01: 106.05
Expand Down
43 changes: 43 additions & 0 deletions policyengine_uk/tests/test_housing_benefit_non_dep_history.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
"""Complete historical HB scale, separate from deduction eligibility rules."""

from pathlib import Path

import numpy as np
import pytest
from policyengine_core.parameters.helpers import load_parameter_file

PATH = (
Path(__file__).resolve().parents[1]
/ "parameters/gov/dwp/housing_benefit/non_dep_deduction/amount.yaml"
)


@pytest.mark.parametrize(
"year, thresholds, amounts",
[
(
2015,
[0, 129, 189, 246, 328, 408],
[14.55, 33.40, 45.85, 75.05, 85.45, 93.80],
),
(
2016,
[0, 133, 195, 253, 338, 420],
[14.65, 33.65, 46.20, 75.60, 86.10, 94.50],
),
(
2017,
[0, 136, 200, 259, 346, 430],
[14.80, 34.00, 46.65, 76.35, 86.95, 95.45],
),
],
)
def test_all_historical_scale_cells(year, thresholds, amounts):
# SI 2015/457 art 18(3); SI 2016/242 reg 5; SI 2017/260 art 22(4).
# Test the parameter itself, not the separate #2007 eligibility/banding fix.
scale = load_parameter_file(str(PATH), "hb_non_dep_scale")(f"{year}-04-30")
assert scale.thresholds == thresholds
assert scale.amounts == amounts
np.testing.assert_allclose(
scale.calc(np.array(thresholds)), amounts, rtol=0, atol=0
)
Loading