-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add 2017-2018 rates to pay-leave-for-parents #2966
Conversation
042a04a
to
5794a3c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.
@@ -30,10 +30,6 @@ The mother and her partner can both get [shared parental pay](/shared-parental-l | |||
|
|||
###Amount | |||
|
|||
Mother’s shared parental pay (between 6 April 2015 and 5 April 2016) | £139.58 per week or 90% of their average weekly earnings (before tax), whichever is lower | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@leenagupte I find here a bit confusing.. Why are 2018 dates affected ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ikennaokpala It's because the original logic says:
if the due date is in not 2013-2014, or not 2014-2015 or not 2015-2016, then display this text. As 2018 doesn't fall in these ranges, the text is displayed.
In the new logic, the text is only displayed if due date IS in 2016-2017, so the text is removed for 2018.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
This is a preparatory commit to make for the changes for the 2017-2018 financial year. In the `_mat_pay` outcome, the 2016-2017 is not specifically referenced. It is just referred to as the current tax year. Of course, when we get to April 6th 2017, this will no longer be true. But if the due date of the child is in the 2016-2017 tax, the user would still see this text. I have added a calculator to check whether the due date plus 39 weeks falls in the 2016-2017 financial year. This calculator is being used in the outcome, and I’ve styled the text to match the other years. There is a bit of oddness in the test artefacts. For due dates in 2012: We don’t have the rate for this year. As doesn’t fall in any other financial year, it was picking up the text and rates for 2016-2017, but obviously this wasn’t correct. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `mat_pay` outcome partial template. To do this I have created a new calculator function to determine whether any part the time frame of the due date plus 39 weeks falls in the 2017-2018 financial year. This follows the same pattern as the other financial years. Updated the expected results file to include a due date in the new financial year. All test artefacts have been updated as expected.
The `mat_allowance` partial outcome template displays text relating to the 2015-20176 tax year if the pay date range falls in the 2015-2016 tax year. However this text is also displayed if the pay date range doesn't fall in the 2013-2014, 2014-2015, 2015-2016 tax years. This means that the text could be displayed for the 2016-2017 and 2017-2018 tax years. Also, I've noticed that there is not text referencing the 2016-2017 tax year. I believe this to be an error, and have fixed both situations by re-using the 2016-2017 calculator function and updating the text. There is a bit of oddness in the test artefacts. For due dates in 2012: We don’t have the rate for this year. As doesn’t fall in any other financial year, it was picking up the text and rates for 2015-2016, but obviously this wasn’t correct. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `mat_allowance` outcome partial template. I am re-using the 2017-2018 tax year calculator function. All test artefacts have updated as expected.
The `additional_pat_pay` partial outcome template displays text relating to the 2015-20176 tax year if the pay date range falls in the 2015-2016 tax year. However this text is also displayed if the pay date range doesn't fall in the 2013-2014, 2014-2015, 2015-2016 tax years. This means that the text could be displayed for the 2016-2017 and 2017-2018 tax years. Also, I've noticed that there is not text referencing the 2016-2017 tax year. I believe this to be an error, and have fixed both situations by re-using the 2016-2017 calculator function and updating the text. There is a bit of oddness in the test artefacts. For due dates in 2012: We don’t have the rate for this year. As doesn’t fall in any other financial year, it was picking up the text and rates for 2015-2016, but obviously this wasn’t correct. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `additional_pat_pay` outcome partial template. I am re-using the 2017-2018 tax year calculator function.
The `pat_pay` partial outcome template displays text relating to the 2015-20176 tax year if the pay date range falls in the 2015-2016 tax year. However this text is also displayed if the pay date range doesn't fall in the 2013-2014, 2014-2015, 2015-2016 tax years. This means that the text could be displayed for the 2016-2017 and 2017-2018 tax years. Also, I've noticed that there is not text referencing the 2016-2017 tax year. I believe this to be an error, and have fixed both situations by re-using the 2016-2017 calculator function and updating the text. There is a bit of oddness in the test artefacts. For due dates in 2012: We don’t have the rate for this year. As doesn’t fall in any other financial year, it was picking up the text and rates for 2015-2016, but obviously this wasn’t correct. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `pat_pay` outcome partial template. I am re-using the 2017-2018 tax year calculator function. Test artefacts have updated as expected.
The `both_shared_pay ` partial outcome template displays text relating to the 2015-20176 tax year if the pay date range falls in the 2015-2016 tax year. However this text is also displayed if the pay date range doesn't fall in the 2013-2014, 2014-2015, 2015-2016 tax years. This means that the text could be displayed for the 2016-2017 and 2017-2018 tax years. Also, I've noticed that there is not text referencing the 2016-2017 tax year. I believe this to be an error, and have fixed both situations by re-using the 2016-2017 calculator function and updating the text. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `both_shared_pay` outcome partial template. I am re-using the 2017-2018 tax year calculator function. Test artefacts have updated as expected.
The `mat_shared_pay` and `pat_shared_pay` partial outcome templates display text relating to the 2015-2016 tax year if the pay date range falls in the 2015-2016 tax year. However this text is also displayed if the pay date range doesn't fall in the 2013-2014, 2014-2015, 2015-2016 tax years. This means that the text could be displayed for the 2016-2017 and 2017-2018 tax years. Also, I've noticed that there is not text referencing the 2016-2017 tax year. I believe this to be an error, and have fixed both situations by re-using the 2016-2017 calculator function and updating the text. Artefacts with an extra line: If the due date plus 39 weeks falls across two financial years, only one line was being displayed. That means that users were not being alerted to the fact that they could receive different pay rates at different times of the 39 weeks.
Add text pertaining to the 2017-2018 tax year to the `mat_shared_pay` and `pat_shared_pay` outcome partial templates. I am re-using the 2017-2018 tax year calculator function. Test artefacts have updated as expected.
At the moment, the 2016-2017 tax year is picking up the default `lower_earnings_amount`, but from the next tax year, this default value will be changing. Updated the `lower_earnings_amount` function to specifically set a value for the `2016-2017` tax year. Unit tests have been updated to include the 2016-2017 financial year. No regression tests were affected by this change.
The `lower_earnings_amount` is changing in the 2017-2018 tax year. Updated the `lower_earnings_amount` calculator function to add this value and updated the default value to match. Unit tests have been updated to include the 2017-2018 financial year. The regression tests for `2012` have been updated because it picks up the default value and that value has changed.
849e349
to
89966c7
Compare
Trello card: https://trello.com/c/Fc1bzWu0
Factcheck
pay-leave-for-parents
Expected changes
The requested changes are to update
pay-leave-for-parents
with the figures for 2017-18, however in order to do this, the rates and text for the 2016-2017 tax year had to be fixed first.Half of the commits add the correct text and logic for parental leave that falls in the 2016-2017 tax year and the other half add the text and logic to display the rates for the 2017-2018 tax year.
Before
After