From a57c02ff058bd2c178999d4a28e0b24953736dbb Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:22:17 +0000
Subject: [PATCH 01/20] AP-5383: Remove from settings and associated specs
---
app/controllers/admin/settings_controller.rb | 1 -
app/forms/settings/setting_form.rb | 2 --
app/models/setting.rb | 4 ---
app/views/admin/settings/show.html.erb | 10 ------
config/application.rb | 3 --
config/locales/en/admin.yml | 2 --
spec/models/setting_spec.rb | 35 -------------------
.../admin/settings_controller_spec.rb | 2 --
8 files changed, 59 deletions(-)
diff --git a/app/controllers/admin/settings_controller.rb b/app/controllers/admin/settings_controller.rb
index 4085d6be41..d3f20f50a0 100644
--- a/app/controllers/admin/settings_controller.rb
+++ b/app/controllers/admin/settings_controller.rb
@@ -25,7 +25,6 @@ def form_params
:linked_applications,
:collect_hmrc_data,
:special_childrens_act,
- :means_test_review_a,
:public_law_family)
end
diff --git a/app/forms/settings/setting_form.rb b/app/forms/settings/setting_form.rb
index 789e034c1a..a654a044d7 100644
--- a/app/forms/settings/setting_form.rb
+++ b/app/forms/settings/setting_form.rb
@@ -9,7 +9,6 @@ class SettingForm < BaseForm
:linked_applications,
:collect_hmrc_data,
:special_childrens_act,
- :means_test_review_a,
:public_law_family
validates :mock_true_layer_data,
@@ -19,7 +18,6 @@ class SettingForm < BaseForm
:linked_applications,
:collect_hmrc_data,
:special_childrens_act,
- :means_test_review_a,
:public_law_family,
presence: true
end
diff --git a/app/models/setting.rb b/app/models/setting.rb
index f8115fdb13..a5801553d2 100644
--- a/app/models/setting.rb
+++ b/app/models/setting.rb
@@ -35,10 +35,6 @@ def self.special_childrens_act?
setting.special_childrens_act
end
- def self.means_test_review_a?
- setting.means_test_review_a && Time.zone.today >= Rails.configuration.x.mtr_a_start_date
- end
-
def self.public_law_family?
setting.public_law_family
end
diff --git a/app/views/admin/settings/show.html.erb b/app/views/admin/settings/show.html.erb
index 6d06dff990..7a2182f470 100644
--- a/app/views/admin/settings/show.html.erb
+++ b/app/views/admin/settings/show.html.erb
@@ -76,16 +76,6 @@
legend: { text: t(".labels.special_childrens_act") },
) %>
- <%= form.govuk_collection_radio_buttons(
- :means_test_review_a,
- yes_no_options,
- :value,
- :label,
- inline: true,
- hint: { text: t(".hints.means_test_review_a", date: Rails.configuration.x.mtr_a_start_date.to_fs) },
- legend: { text: t(".labels.means_test_review_a") },
- ) %>
-
<%= form.govuk_collection_radio_buttons(
:public_law_family,
yes_no_options,
diff --git a/config/application.rb b/config/application.rb
index 9ad8daa921..944c226a3a 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -133,9 +133,6 @@ class Application < Rails::Application
config.x.maintenance_mode = ENV.fetch("MAINTENANCE_MODE", nil)&.downcase&.eql?("true")
- # TODO: Remove with Setting.means_test_review_a feature flag #
- config.x.mtr_a_start_date = Date.parse(ENV.fetch("MTR_A_START_DATE", "2024-11-20"))
-
# automatically include locale in the query string when generating urls with url_helpers
Rails.application.routes.default_url_options[:locale] = I18n.locale
config.i18n.default_locale = :en
diff --git a/config/locales/en/admin.yml b/config/locales/en/admin.yml
index 92a3e4a1f4..93be70387e 100644
--- a/config/locales/en/admin.yml
+++ b/config/locales/en/admin.yml
@@ -75,7 +75,6 @@ en:
linked_applications: Enable linking and copying cases
collect_hmrc_data: Collect HMRC data
special_childrens_act: Enable Special Childrens Act
- means_test_review_a: Enable Means Test Review (MTR) A
public_law_family: Enable Public Law Family
hints:
mock_true_layer_data: Select Yes and TrueLayer data will be replaced by mock data from %{bank_transaction_filename}
@@ -88,7 +87,6 @@ en:
linked_applications: Select Yes to enable the linking and copying cases feature for solicitors
collect_hmrc_data: Select Yes to enable calls to HMRC for employment data
special_childrens_act: Select Yes to enable the special childrens act matter type
- means_test_review_a: Select Yes to enable the Means Test Review (MTR) A feature after %{date}
public_law_family: Select Yes to enable Public Law Family feature
update:
diff --git a/spec/models/setting_spec.rb b/spec/models/setting_spec.rb
index e360016e9a..9251d6fa82 100644
--- a/spec/models/setting_spec.rb
+++ b/spec/models/setting_spec.rb
@@ -16,7 +16,6 @@
expect(rec.linked_applications?).to be false
expect(rec.collect_hmrc_data?).to be false
expect(rec.special_childrens_act?).to be false
- expect(rec.means_test_review_a?).to be false
expect(rec.public_law_family?).to be false
end
end
@@ -33,7 +32,6 @@
linked_applications: true,
collect_hmrc_data: true,
special_childrens_act: true,
- means_test_review_a: true,
public_law_family: true,
)
end
@@ -49,7 +47,6 @@
expect(rec.linked_applications?).to be true
expect(rec.collect_hmrc_data?).to be true
expect(rec.special_childrens_act?).to be true
- expect(rec.means_test_review_a?).to be true
expect(rec.public_law_family?).to be true
end
end
@@ -68,39 +65,7 @@
expect(described_class.linked_applications?).to be false
expect(described_class.collect_hmrc_data?).to be false
expect(described_class.special_childrens_act?).to be false
- expect(described_class.means_test_review_a?).to be false
expect(described_class.public_law_family?).to be false
end
-
- describe ".means_test_review_a?" do
- subject { described_class.means_test_review_a? }
-
- context "when the flag is true and a date has been set in the future" do
- before do
- described_class.setting.update!(means_test_review_a: true)
- allow(Rails.configuration.x).to receive(:mtr_a_start_date).and_return(Date.tomorrow)
- end
-
- it { is_expected.to be false }
- end
-
- context "when the flag is true and a date has been set in the past" do
- before do
- described_class.setting.update!(means_test_review_a: true)
- allow(Rails.configuration.x).to receive(:mtr_a_start_date).and_return(Date.yesterday)
- end
-
- it { is_expected.to be true }
- end
-
- context "when the flag is false and a date has been set in the past" do
- before do
- described_class.setting.update!(means_test_review_a: false)
- allow(Rails.configuration.x).to receive(:mtr_a_start_date).and_return(Date.yesterday)
- end
-
- it { is_expected.to be false }
- end
- end
end
end
diff --git a/spec/requests/admin/settings_controller_spec.rb b/spec/requests/admin/settings_controller_spec.rb
index 42ddec6da0..6910c382f8 100644
--- a/spec/requests/admin/settings_controller_spec.rb
+++ b/spec/requests/admin/settings_controller_spec.rb
@@ -44,7 +44,6 @@
collect_hmrc_data: "true",
home_address: "true",
special_childrens_act: "true",
- means_test_review_a: "true",
public_law_family: "true",
},
}
@@ -62,7 +61,6 @@
expect(setting.linked_applications?).to be(true)
expect(setting.collect_hmrc_data?).to be(true)
expect(setting.special_childrens_act?).to be(true)
- expect(setting.means_test_review_a?).to be(true)
expect(setting.public_law_family?).to be(true)
end
From 19815047ce479107723463de345623a8f16d04ba Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:24:31 +0000
Subject: [PATCH 02/20] AP-5383: Remove from steps and associated specs
---
.../provider_capital/other_assets_step.rb | 2 +-
.../provider_capital/policy_disregards_step.rb | 8 +-------
.../provider_capital/restrictions_step.rb | 2 +-
.../means/other_assets_controller_spec.rb | 15 ++-------------
.../provider_capital/other_assets_step_spec.rb | 2 +-
.../policy_disregards_step_spec.rb | 18 ++----------------
.../provider_capital/restrictions_step_spec.rb | 12 +-----------
7 files changed, 9 insertions(+), 50 deletions(-)
diff --git a/app/services/flow/steps/provider_capital/other_assets_step.rb b/app/services/flow/steps/provider_capital/other_assets_step.rb
index 99946fb4ef..866008236e 100644
--- a/app/services/flow/steps/provider_capital/other_assets_step.rb
+++ b/app/services/flow/steps/provider_capital/other_assets_step.rb
@@ -7,7 +7,7 @@ module ProviderCapital
if application.own_capital?
:restrictions
elsif application.capture_policy_disregards?
- Setting.means_test_review_a? ? :capital_disregards_mandatory : :policy_disregards
+ :capital_disregards_mandatory
else
application.passported? ? :check_passported_answers : :check_capital_answers
end
diff --git a/app/services/flow/steps/provider_capital/policy_disregards_step.rb b/app/services/flow/steps/provider_capital/policy_disregards_step.rb
index ebb78e9cf8..fe1c8e0df7 100644
--- a/app/services/flow/steps/provider_capital/policy_disregards_step.rb
+++ b/app/services/flow/steps/provider_capital/policy_disregards_step.rb
@@ -3,13 +3,7 @@ module Steps
module ProviderCapital
PolicyDisregardsStep = Step.new(
path: ->(application) { Steps.urls.providers_legal_aid_application_means_policy_disregards_path(application) },
- forward: lambda do |application|
- if Setting.means_test_review_a?
- :capital_disregards_discretionary
- else
- application.passported? ? :check_passported_answers : :check_capital_answers
- end
- end,
+ forward: :capital_disregards_discretionary,
check_answers: ->(application) { application.provider_checking_or_checked_citizens_means_answers? ? :check_capital_answers : :check_passported_answers },
)
end
diff --git a/app/services/flow/steps/provider_capital/restrictions_step.rb b/app/services/flow/steps/provider_capital/restrictions_step.rb
index db43b0f5f5..51cf278770 100644
--- a/app/services/flow/steps/provider_capital/restrictions_step.rb
+++ b/app/services/flow/steps/provider_capital/restrictions_step.rb
@@ -5,7 +5,7 @@ module ProviderCapital
path: ->(application) { Steps.urls.providers_legal_aid_application_means_restrictions_path(application) },
forward: lambda do |application|
if application.capture_policy_disregards?
- Setting.means_test_review_a? ? :capital_disregards_mandatory : :policy_disregards
+ :capital_disregards_mandatory
else
application.passported? ? :check_passported_answers : :check_capital_answers
end
diff --git a/spec/requests/providers/means/other_assets_controller_spec.rb b/spec/requests/providers/means/other_assets_controller_spec.rb
index 21d2764172..5953da2af2 100644
--- a/spec/requests/providers/means/other_assets_controller_spec.rb
+++ b/spec/requests/providers/means/other_assets_controller_spec.rb
@@ -208,7 +208,6 @@
let(:mtr2a_flag) { false }
before do
- allow(Setting).to receive(:means_test_review_a?).and_return(mtr2a_flag)
allow(application).to receive(:capture_policy_disregards?).and_return(policy_disregards)
patch providers_legal_aid_application_means_other_assets_path(oad.legal_aid_application), params: empty_params.merge(submit_button)
end
@@ -249,18 +248,8 @@
end
end
- context "when MTR2A flag is on" do
- let(:mtr2a_flag) { true }
-
- it "redirects to the mandatory_disregards page" do
- expect(response).to redirect_to(providers_legal_aid_application_means_capital_disregards_mandatory_path(application))
- end
- end
-
- context "when MTR2A flag is off" do
- it "redirects to the legacy policy_disregards page" do
- expect(response).to redirect_to(providers_legal_aid_application_means_policy_disregards_path(application))
- end
+ it "redirects to the mandatory_disregards page" do
+ expect(response).to redirect_to(providers_legal_aid_application_means_capital_disregards_mandatory_path(application))
end
end
end
diff --git a/spec/services/flow/steps/provider_capital/other_assets_step_spec.rb b/spec/services/flow/steps/provider_capital/other_assets_step_spec.rb
index 1a9eef2b30..22c5d4bc6c 100644
--- a/spec/services/flow/steps/provider_capital/other_assets_step_spec.rb
+++ b/spec/services/flow/steps/provider_capital/other_assets_step_spec.rb
@@ -32,7 +32,7 @@
context "when capture_policy_disregards is true" do
let(:capture_policy_disregards?) { true }
- it { is_expected.to eq :policy_disregards }
+ it { is_expected.to eq :capital_disregards_mandatory }
end
context "when passported is true" do
diff --git a/spec/services/flow/steps/provider_capital/policy_disregards_step_spec.rb b/spec/services/flow/steps/provider_capital/policy_disregards_step_spec.rb
index 02a386874d..8d87aea003 100644
--- a/spec/services/flow/steps/provider_capital/policy_disregards_step_spec.rb
+++ b/spec/services/flow/steps/provider_capital/policy_disregards_step_spec.rb
@@ -17,23 +17,9 @@
end
describe "#forward" do
- subject { described_class.forward.call(legal_aid_application) }
+ subject { described_class.forward }
- context "when passported is true" do
- let(:passported?) { true }
-
- it { is_expected.to eq :check_passported_answers }
- end
-
- context "when passported is not true" do
- it { is_expected.to eq :check_capital_answers }
- end
-
- context "when means_test_review_a is enabled" do
- before { allow(Setting).to receive(:means_test_review_a?).and_return(true) }
-
- it { is_expected.to eq :capital_disregards_discretionary }
- end
+ it { is_expected.to eq :capital_disregards_discretionary }
end
describe "#check_answers" do
diff --git a/spec/services/flow/steps/provider_capital/restrictions_step_spec.rb b/spec/services/flow/steps/provider_capital/restrictions_step_spec.rb
index 7a41176009..2cf2d67be3 100644
--- a/spec/services/flow/steps/provider_capital/restrictions_step_spec.rb
+++ b/spec/services/flow/steps/provider_capital/restrictions_step_spec.rb
@@ -21,17 +21,7 @@
describe "#forward" do
subject { described_class.forward.call(legal_aid_application) }
- context "when capture_policy_disregards is true and mtr2 accelerated measures is disabled" do
- before { allow(Setting).to receive(:means_test_review_a?).and_return(false) }
-
- let(:capture_policy_disregards?) { true }
-
- it { is_expected.to eq :policy_disregards }
- end
-
- context "when capture_policy_disregards is true and mtr2 accelerated measures is enabled" do
- before { allow(Setting).to receive(:means_test_review_a?).and_return(true) }
-
+ context "when capture_policy_disregards is true" do
let(:capture_policy_disregards?) { true }
it { is_expected.to eq :capital_disregards_mandatory }
From 224768506336a6f79aebd6e8c9074af51e700bfa Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:30:55 +0000
Subject: [PATCH 03/20] AP-5383: Update disregarded benefits page
Remove references to mtr2a and remove now outdated locales files
---
...f_living_and_disregarded_benefits.html.erb | 10 +-
config/locales/en/shared.yml | 119 ++++++------------
2 files changed, 44 insertions(+), 85 deletions(-)
diff --git a/app/views/shared/means/_cost_of_living_and_disregarded_benefits.html.erb b/app/views/shared/means/_cost_of_living_and_disregarded_benefits.html.erb
index 3b26fdf3e2..dff35e7062 100644
--- a/app/views/shared/means/_cost_of_living_and_disregarded_benefits.html.erb
+++ b/app/views/shared/means/_cost_of_living_and_disregarded_benefits.html.erb
@@ -8,15 +8,13 @@
<% end %>
- <% mtra_scope = Setting.means_test_review_a? ? :mtra : :pre_mtra %>
-
-
<%= t("shared.disregarded_benefits.#{mtra_scope}.header") %>
- <%= t("shared.disregarded_benefits.#{mtra_scope}.text") %>
+ <%= t("shared.disregarded_benefits.header") %>
+ <%= t("shared.disregarded_benefits.text") %>
<% %w[carer_disability low_income other].each do |category| %>
- <%= t("shared.disregarded_benefits.#{mtra_scope}.#{category}.heading") %>
+ <%= t("shared.disregarded_benefits.#{category}.heading") %>
- <% t("shared.disregarded_benefits.#{mtra_scope}.#{category}.list_html").each do |item| %>
+ <% t("shared.disregarded_benefits.#{category}.list_html").each do |item| %>
- <%= item %>
<% end %>
diff --git a/config/locales/en/shared.yml b/config/locales/en/shared.yml
index f8dc3197a6..184a39f0fc 100644
--- a/config/locales/en/shared.yml
+++ b/config/locales/en/shared.yml
@@ -222,85 +222,46 @@ en:
- Energy Bills Support Scheme (EBSS)
- Payments for those who are not served by mains gas
disregarded_benefits:
- mtra:
- header: Disregarded benefits and payments
- text: The following are disregarded from the financial eligibility calculation. They are known as mandatory disregards.
- carer_disability:
- heading: Carer and disability
- list_html:
- - Attendance Allowance
- - Carer's Allowance
- - Community Care Direct Payments
- - Constant Attendance Allowance
- - Disability Living Allowance
- - Exceptionally Severe Disablement Allowance
- - Independent Living Fund
- - Payments on account of benefit
- - Personal Independence Payments (PIP)
- - Severe Disablement Allowance
- - Special Education Needs (SEN) Direct Payment
- - Welsh Independent Living Grant
- low_income:
- heading: Low income
- list_html:
- - Budgeting Advance
- - Housing Benefit
- - Social Fund Funeral Payment
- - Social Fund payments
- - Universal Credit advance payments
- other:
- heading: Other
- list_html:
- - Armed Forces Independence Payment
- - Compensation for miscarriage of justice
- - Foster Carers Allowance
- - Grenfell Tower Residents' Discretionary Fund
- - Grenfell Tower fire victims payments
- - "Infected Blood Support Scheme
Includes Infected Blood Interim Compensation Payment Scheme, Infected Blood Further Interim Compensation Scheme, Infected Blood Compensation Scheme, arrangements made under section 56(1) of the Victims and Prisoners Act 2024 or earlier support schemes"
- - Modern Slavery Victim Care Contract (MSVCC) payments
- - Scotland and Northern Ireland Redress Schemes for historical child abuse payment
- - War Pensions Scheme payments
- - War Widow(er) Pension
- - Windrush Compensation Scheme Payments
- pre_mtra:
- header: Disregarded benefits
- text: The following benefits are disregarded from the financial eligibility calculation. They are known as mandatory disregards.
- carer_disability:
- heading: Carer and disability benefits
- list_html:
- - Attendance Allowance
- - Carer's Allowance
- - Community Care Direct Payments
- - Constant Attendance Allowance
- - Disability Living Allowance
- - Exceptionally Severe Disablement Allowance
- - Independent Living Fund
- - Payments on account of benefit
- - Personal Independence Payments (PIP)
- - Severe Disablement Allowance
- - Special Education Needs (SEN) Direct Payment
- - Welsh Independent Living Grant
- low_income:
- heading: Low income benefits
- list_html:
- - Benefit Transfer Advance (Universal Credit)
- - Budgeting Advance
- - Council Tax Reduction
- - Earnings Top-up (ETU)
- - Housing Benefit
- - Social Fund Funeral Payment
- - Social Fund payments
- other:
- heading: Other benefits
- list_html:
- - Armed Forces Independence Payment
- - Foster Carers Allowance
- - Grenfell Tower Residents' Discretionary Fund
- - Grenfell Tower fire victims payments
- - War Pensions Scheme payments
- - War Widow(er) Pension
- - Widow's Pension lump sum payments
- - Windrush Compensation Scheme Payments
+ header: Disregarded benefits and payments
+ text: The following are disregarded from the financial eligibility calculation. They are known as mandatory disregards.
+ carer_disability:
+ heading: Carer and disability
+ list_html:
+ - Attendance Allowance
+ - Carer's Allowance
+ - Community Care Direct Payments
+ - Constant Attendance Allowance
+ - Disability Living Allowance
+ - Exceptionally Severe Disablement Allowance
+ - Independent Living Fund
+ - Payments on account of benefit
+ - Personal Independence Payments (PIP)
+ - Severe Disablement Allowance
+ - Special Education Needs (SEN) Direct Payment
+ - Welsh Independent Living Grant
+ low_income:
+ heading: Low income
+ list_html:
+ - Budgeting Advance
+ - Housing Benefit
+ - Social Fund Funeral Payment
+ - Social Fund payments
+ - Universal Credit advance payments
+ other:
+ heading: Other
+ list_html:
+ - Armed Forces Independence Payment
+ - Compensation for miscarriage of justice
+ - Foster Carers Allowance
+ - Grenfell Tower Residents' Discretionary Fund
+ - Grenfell Tower fire victims payments
+ - "Infected Blood Support Scheme
Includes Infected Blood Interim Compensation Payment Scheme, Infected Blood Further Interim Compensation Scheme, Infected Blood Compensation Scheme, arrangements made under section 56(1) of the Victims and Prisoners Act 2024 or earlier support schemes"
+ - Modern Slavery Victim Care Contract (MSVCC) payments
+ - Scotland and Northern Ireland Redress Schemes for historical child abuse payment
+ - War Pensions Scheme payments
+ - War Widow(er) Pension
+ - Windrush Compensation Scheme Payments
+
means_report:
income_details:
total_income: Total income
From c3a3cbad34022451451ffc54e1f264acdc3d84d4 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:33:17 +0000
Subject: [PATCH 04/20] AP-5383: Update own_homes page
Remove references to mtr2a and remove now outdated locales files
---
.../providers/means/own_homes/show.html.erb | 5 ++--
config/locales/en/providers.yml | 3 --
.../means/own_home_controller_spec.rb | 29 +++----------------
3 files changed, 6 insertions(+), 31 deletions(-)
diff --git a/app/views/providers/means/own_homes/show.html.erb b/app/views/providers/means/own_homes/show.html.erb
index b52cdaaea4..377fde32e0 100644
--- a/app/views/providers/means/own_homes/show.html.erb
+++ b/app/views/providers/means/own_homes/show.html.erb
@@ -1,5 +1,4 @@
-<% prefix = Setting.means_test_review_a? ? "" : ".legacy"
- heading = @legal_aid_application.applicant.has_partner_with_no_contrary_interest? ? "#{prefix}.h1_heading_with_partner" : "#{prefix}.h1_heading" %>
+<% heading = @legal_aid_application.applicant.has_partner_with_no_contrary_interest? ? ".h1_heading_with_partner" : ".h1_heading" %>
<%= form_with(
model: @form,
url: providers_legal_aid_application_means_own_home_path(@legal_aid_application),
@@ -18,7 +17,7 @@
<%= form.govuk_collection_radio_buttons(:own_home, options, :first, :second,
legend: { size: "xl", tag: "h1", text: content_for(:page_title) },
- hint: { text: Setting.means_test_review_a? ? t(".hint") : "" }) %>
+ hint: { text: t(".hint") }) %>
<%= next_action_buttons(show_draft: true, form:) %>
<% end %>
diff --git a/config/locales/en/providers.yml b/config/locales/en/providers.yml
index 8bc97f8203..859b035c22 100644
--- a/config/locales/en/providers.yml
+++ b/config/locales/en/providers.yml
@@ -1110,9 +1110,6 @@ en:
h1_heading: Does your client own the home they usually live in?
h1_heading_with_partner: Does your client or their partner own the home your client usually lives in?
hint: This is where your client normally lives, even if they have temporarily left their home due to domestic abuse.
- legacy:
- h1_heading: Does your client own the home that they live in?
- h1_heading_with_partner: Does your client or their partner own the home your client lives in?
mortgage: Yes, with a mortgage or loan
'no': 'No'
owned_outright: Yes, owned outright
diff --git a/spec/requests/providers/means/own_home_controller_spec.rb b/spec/requests/providers/means/own_home_controller_spec.rb
index 19d9134d9e..5b1ded5ab4 100644
--- a/spec/requests/providers/means/own_home_controller_spec.rb
+++ b/spec/requests/providers/means/own_home_controller_spec.rb
@@ -15,7 +15,6 @@
context "when the provider is authenticated" do
before do
- allow(Setting).to receive(:means_test_review_a?).and_return(means_test_flag)
login_as provider
request
end
@@ -27,36 +26,16 @@
end
context "without a partner" do
- context "when the means_test_review_a flag is enabled" do
- it "shows the correct content" do
- expect(response.body).to include(I18n.t("providers.means.own_homes.show.h1_heading"))
- end
- end
-
- context "when the means_test_review_a flag is turned off" do
- let(:means_test_flag) { false }
-
- it "shows the correct content" do
- expect(response.body).to include(I18n.t("providers.means.own_homes.show.legacy.h1_heading"))
- end
+ it "shows the correct content" do
+ expect(response.body).to include(I18n.t("providers.means.own_homes.show.h1_heading"))
end
end
context "with a partner" do
let(:legal_aid_application) { create(:legal_aid_application, :with_applicant_and_partner) }
- context "when the means_test_review_a flag is enabled" do
- it "shows the correct content" do
- expect(response.body).to include(I18n.t("providers.means.own_homes.show.h1_heading_with_partner"))
- end
- end
-
- context "when the means_test_review_a flag is turned off" do
- let(:means_test_flag) { false }
-
- it "shows the correct content" do
- expect(response.body).to include(I18n.t("providers.means.own_homes.show.legacy.h1_heading_with_partner"))
- end
+ it "shows the correct content" do
+ expect(response.body).to include(I18n.t("providers.means.own_homes.show.h1_heading_with_partner"))
end
end
end
From c39de20d60ecb4542c6d9f4cddfc7c098bc1865b Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:36:31 +0000
Subject: [PATCH 05/20] AP-5383: Update property_details page
Remove references to mtr2a and remove now outdated locales files
---
app/views/providers/means/property_details/show.html.erb | 5 ++---
config/locales/en/providers.yml | 3 ---
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/app/views/providers/means/property_details/show.html.erb b/app/views/providers/means/property_details/show.html.erb
index 1004378053..755c879594 100644
--- a/app/views/providers/means/property_details/show.html.erb
+++ b/app/views/providers/means/property_details/show.html.erb
@@ -5,15 +5,14 @@
method: :patch,
local: true,
) do |form| %>
- <% prefix = Setting.means_test_review_a? ? "" : "legacy."
- individual = @legal_aid_application.applicant.has_partner_with_no_contrary_interest? ? "partner" : "client" %>
+ <% individual = @legal_aid_application.applicant.has_partner_with_no_contrary_interest? ? "partner" : "client" %>
<%= page_template page_title: t(".h1-heading"), form:, template: :basic do %>
<%= form.govuk_fieldset legend: { size: "xl", tag: "h1", text: t(".h1-heading") } do %>
<%= form.govuk_text_field :property_value,
- label: { text: t(".values_question.#{prefix}#{individual}"), tag: "h2", size: "m" },
+ label: { text: t(".values_question.#{individual}"), tag: "h2", size: "m" },
hint: { text: t(".values_hint") },
prefix_text: t("currency.gbp"),
classes: "govuk-!-margin-top-6",
diff --git a/config/locales/en/providers.yml b/config/locales/en/providers.yml
index 859b035c22..1f5db5ffd7 100644
--- a/config/locales/en/providers.yml
+++ b/config/locales/en/providers.yml
@@ -1119,9 +1119,6 @@ en:
values_question:
client: How much is the home they usually live in worth?
partner: How much is the home worth where your client and their partner usually live?
- legacy:
- client: How much is the home your client lives in worth?
- partner: How much is the home your client and their partner live in worth?
values_hint: You can use property websites to find the estimated value.
mortgage_question: How much is left to pay on the mortgage?
mortgage_hint:
From cc8299e0ff39d36b984fc3d4e462aa6d1fd05042 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:38:35 +0000
Subject: [PATCH 06/20] AP-5383: Update property partial
Remove references to mtr2a and remove now outdated locales files
---
app/views/shared/check_answers/_property.html.erb | 4 ++--
config/locales/en/shared.yml | 5 -----
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/app/views/shared/check_answers/_property.html.erb b/app/views/shared/check_answers/_property.html.erb
index 7d7c2bc699..7fbaedcc22 100644
--- a/app/views/shared/check_answers/_property.html.erb
+++ b/app/views/shared/check_answers/_property.html.erb
@@ -7,7 +7,7 @@
html_attributes: { id: "property-question" },
) do |summary_list| %>
<%= summary_list.with_row(html_attributes: { id: "app-check-your-answers__own_home" }) do |row| %>
- <%= row.with_key(text: t("shared.check_answers.assets.property#{'.legacy' unless Setting.means_test_review_a?}.own_home#{individual}"), classes: "govuk-!-width-one-half") %>
+ <%= row.with_key(text: t("shared.check_answers.assets.property.own_home#{individual}"), classes: "govuk-!-width-one-half") %>
<%= row.with_value { @legal_aid_application.own_home.blank? ? "" : t("shared.forms.own_home_form.#{@legal_aid_application.own_home}") } %>
<%= row.with_action(
text: t("generic.change"),
@@ -25,7 +25,7 @@
html_attributes: { id: "property-details-questions" },
) do |summary_list| %>
<%= summary_list.with_row(html_attributes: { id: "app-check-your-answers__property_value" }) do |row| %>
- <%= row.with_key(text: t("shared.check_answers.assets.property#{'.legacy' unless Setting.means_test_review_a?}.property_value#{individual}"), classes: "govuk-!-width-one-half") %>
+ <%= row.with_key(text: t("shared.check_answers.assets.property.property_value#{individual}"), classes: "govuk-!-width-one-half") %>
<%= row.with_value { gds_number_to_currency(@legal_aid_application.property_value) } %>
<%= row.with_action(
text: t("generic.change"),
diff --git a/config/locales/en/shared.yml b/config/locales/en/shared.yml
index 184a39f0fc..19586db0c8 100644
--- a/config/locales/en/shared.yml
+++ b/config/locales/en/shared.yml
@@ -351,11 +351,6 @@ en:
own_home_with_partner: Does your client or their partner own the home your client usually lives in?
property_value: How much is the home they usually live in worth?
property_value_with_partner: How much is the home your client and their partner usually live in worth?
- legacy:
- own_home: Does your client own the home that they live in?
- own_home_with_partner: Does your client or their partner own the home that they live in?
- property_value: How much is the home your client lives in worth?
- property_value_with_partner: How much is the home your client and their partner live in worth?
outstanding_mortgage: How much is left to pay on the mortgage?
shared_ownership: Does your client own the home with anyone else?
shared_ownership_with_partner: Does your client or their partner own the home with anyone else?
From 5ec53376f4d0c1ff912dbffd27589189641cd0af Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:43:34 +0000
Subject: [PATCH 07/20] AP-5383: Update assets partial
---
app/views/shared/check_answers/_assets.html.erb | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/app/views/shared/check_answers/_assets.html.erb b/app/views/shared/check_answers/_assets.html.erb
index 005bb50f4d..ea20dc66eb 100644
--- a/app/views/shared/check_answers/_assets.html.erb
+++ b/app/views/shared/check_answers/_assets.html.erb
@@ -197,12 +197,10 @@
<%# capital disregards %>
- <% if Setting.means_test_review_a? %>
- <% if means_report %>
- <%= render("providers/means_reports/capital_disregards", read_only:, individual:) %>
- <% else %>
- <%= render("shared/check_answers/capital_disregards", read_only:, individual:) %>
- <% end %>
+ <% if means_report %>
+ <%= render("providers/means_reports/capital_disregards", read_only:, individual:) %>
+ <% else %>
+ <%= render("shared/check_answers/capital_disregards", read_only:, individual:) %>
<% end %>
From c600b11574ad547632011eab57a20192087aaba3 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:53:08 +0000
Subject: [PATCH 08/20] AP-5383: Update humanized currency feature
Remove reference to MTR2A and instead just always run the test
---
.../regressions/enter_humanized_currency_amounts.feature | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/features/providers/regressions/enter_humanized_currency_amounts.feature b/features/providers/regressions/enter_humanized_currency_amounts.feature
index bb4588c146..f5f8bad0e5 100644
--- a/features/providers/regressions/enter_humanized_currency_amounts.feature
+++ b/features/providers/regressions/enter_humanized_currency_amounts.feature
@@ -115,9 +115,7 @@ Feature: Entering humanized monetary amounts on various forms
And I should see "£2,322.22"
Scenario: I can enter humanized monetary amounts like 1,000 for mandatory capital disregards
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed the income and capital sections of a non-passported application with bank statement uploads post-MTRA
+ Given I have completed the income and capital sections of a non-passported application with bank statement uploads
When I am viewing the means capital check your answers page
When I click link "Change Budgeting Advances"
@@ -128,9 +126,7 @@ Feature: Entering humanized monetary amounts on various forms
And I should see "£1,654.33"
Scenario: I can enter humanized monetary amounts like 1,000 for discretionary capital disregards
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed the income and capital sections of a non-passported application with bank statement uploads post-MTRA
+ Given I have completed the income and capital sections of a non-passported application with bank statement uploads
When I am viewing the means capital check your answers page
When I click link "Change Compensation, damages or ex-gratia payments for personal harm"
From b9c69165299ddc60771882272c8297e8ed48adce Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 16:59:22 +0000
Subject: [PATCH 09/20] AP-5383: Replace means_report feature with MTR2A
version
---
features/providers/means_report.feature | 79 ++--
.../mtr_accelerated/means_report.feature | 443 ------------------
.../step_definitions/means_report_steps.rb | 150 ------
3 files changed, 48 insertions(+), 624 deletions(-)
delete mode 100644 features/providers/mtr_accelerated/means_report.feature
diff --git a/features/providers/means_report.feature b/features/providers/means_report.feature
index 66271bcab0..2f7023d33a 100644
--- a/features/providers/means_report.feature
+++ b/features/providers/means_report.feature
@@ -24,7 +24,7 @@ Feature: Means report
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | Capital disregards |
| h3 | Bank statements |
Then the following sections should not exist:
@@ -40,6 +40,7 @@ Feature: Means report
| h2 | Declared cash income |
| h2 | Declared outgoings categories |
| h2 | Declared cash outgoings |
+ | h2 | Payments from scheme or charities |
And the Client details questions should exist:
| question |
@@ -54,6 +55,10 @@ Feature: Means report
| Extend, variation or discharge - Part IV |
| Variation or discharge under section 5 protection from harassment act 1997 |
+ And the Passported means question and answer should match:
+ | question | answer |
+ | In receipt of passporting benefit | No |
+
And the Income result questions should exist:
| question |
| Total gross income assessed |
@@ -87,9 +92,9 @@ Feature: Means report
| Client childcare payments | £0 |
| Client maintenance payments to a former partner | £0 |
| Client payments towards legal aid in a criminal case | £100 |
- | Dependants allowance | £0 |
+ | Dependants allowance | £0 |
| Total outgoings and deductions | £225 |
-
+
And the Dependants questions should exist:
| question |
| Does your client have any dependants? |
@@ -102,8 +107,11 @@ Feature: Means report
And the Caseworker review section should contain:
| question | answer |
| Caseworker review required? | Yes |
- | Review reasons | Client's bank statements uploaded |
+ | Review reasons | Restrictions on client's assets |
+ | Review reasons | Capital disregards declared |
| Review reasons | Non-Passported application |
+ | Review reasons | Client's further employment details |
+ | Review reasons | Client's bank statements uploaded |
And the Capital result questions should exist:
| question |
@@ -114,11 +122,11 @@ Feature: Means report
And the Property question should exist:
| question |
- | Does your client own the home that they live in? |
+ | Does your client own the home they usually live in? |
And the Property details questions should exist:
| question |
- | How much is the home your client lives in worth? |
+ | How much is the home they usually live in worth? |
| How much is left to pay on the mortgage? |
| Does your client own the home with anyone else? |
| What percentage of the home does your client legally own? |
@@ -164,15 +172,10 @@ Feature: Means report
| Is your client banned from selling or borrowing against their assets? |
| Details of restrictions |
- And the "Payments from scheme or charities" questions should exist:
- | question |
- | England Infected Blood Support Scheme |
- | Vaccine Damage Payments Scheme |
- | Variant Creutzfeldt-Jakob disease (vCJD) Trust |
- | Criminal Injuries Compensation Scheme |
- | National Emergencies Trust (NET) |
- | We Love Manchester Emergency Fund |
- | The London Emergencies Trust |
+ And the Capital disregards questions and answers should match:
+ | question | answer |
+ | Mandatory disregards | Budgeting Advances\n£1,001 on 8 August 2024\nHeld in Halifax |
+ | Discretionary disregards | Compensation, damages or ex-gratia payments for personal harm\nFor: life changing injuries\n£1,002 on 8 August 2024\nHeld in Halifax |
Scenario: For a non-passported truelayer bank transactions journey
Given I have completed a non-passported application with truelayer
@@ -187,6 +190,7 @@ Feature: Means report
| h2 | Income |
| h3 | Client employment income |
| h2 | Outgoings and deductions |
+ | h2 | Dependants |
| h2 | Caseworker Review |
| h2 | Capital result |
| h2 | Property, savings and other assets |
@@ -198,7 +202,7 @@ Feature: Means report
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | Capital disregards |
| h2 | Client's bank accounts |
Then the following sections should not exist:
@@ -209,6 +213,7 @@ Feature: Means report
| h2 | Declared cash income |
| h2 | Declared outgoings categories |
| h2 | Declared cash outgoings |
+ | h2 | Payments from scheme or charities |
| h3 | Bank statements |
And the Client details questions should exist:
@@ -224,6 +229,10 @@ Feature: Means report
| Extend, variation or discharge - Part IV |
| Variation or discharge under section 5 protection from harassment act 1997 |
+ And the Passported means question and answer should match:
+ | question | answer |
+ | In receipt of passporting benefit | No |
+
And the Income result questions should exist:
| question |
| Total gross income assessed |
@@ -260,15 +269,22 @@ Feature: Means report
| Dependants allowance | £0 |
| Total outgoings and deductions | £225 |
- And the Caseworker review questions should exist:
+ And the Dependants questions should exist:
| question |
- | Caseworker review required? |
- | Review reasons |
+ | Does your client have any dependants? |
+
+ And the Dependants detail questions should exist:
+ | Name |
+ | Date of birth |
+ | What is their relationship to your client? |
And the Caseworker review section should contain:
| question | answer |
| Caseworker review required? | Yes |
+ | Review reasons | Restrictions on client's assets |
+ | Review reasons | Capital disregards declared |
| Review reasons | Non-Passported application |
+ | Review reasons | Client's further employment details |
And the Capital result questions should exist:
| question |
@@ -279,11 +295,11 @@ Feature: Means report
And the Property question should exist:
| question |
- | Does your client own the home that they live in? |
+ | Does your client own the home they usually live in? |
And the Property details questions should exist:
| question |
- | How much is the home your client lives in worth? |
+ | How much is the home they usually live in worth? |
| How much is left to pay on the mortgage? |
| Does your client own the home with anyone else? |
| What percentage of the home does your client legally own? |
@@ -339,15 +355,10 @@ Feature: Means report
| Is your client banned from selling or borrowing against their assets? |
| Details of restrictions |
- And the "Payments from scheme or charities" questions should exist:
- | question |
- | England Infected Blood Support Scheme |
- | Vaccine Damage Payments Scheme |
- | Variant Creutzfeldt-Jakob disease (vCJD) Trust |
- | Criminal Injuries Compensation Scheme |
- | National Emergencies Trust (NET) |
- | We Love Manchester Emergency Fund |
- | The London Emergencies Trust |
+ And the Capital disregards questions and answers should match:
+ | question | answer |
+ | Mandatory disregards | Budgeting Advances\n£1,001 on 8 August 2024\nHeld in Halifax |
+ | Discretionary disregards | Compensation, damages or ex-gratia payments for personal harm\nFor: life changing injuries\n£1,002 on 8 August 2024\nHeld in Halifax |
Scenario: For a passported journey
Given I have completed a passported application
@@ -366,7 +377,7 @@ Feature: Means report
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | Capital disregards |
| h2 | Caseworker Review |
Then the following sections should not exist:
@@ -381,8 +392,13 @@ Feature: Means report
| h2 | Dependants |
| h2 | Declared outgoings categories |
| h2 | Declared cash outgoings |
+ | h2 | Payments from scheme or charities |
| h3 | Bank statements |
+ And the Passported means question and answer should match:
+ | question | answer |
+ | In receipt of passporting benefit | Yes |
+
Scenario: For a non means tested journey
Given I have completed a non means tested application
When I view the means report
@@ -410,6 +426,7 @@ Feature: Means report
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
| h2 | Payments from scheme or charities |
+ | h2 | Capital disregards |
| h3 | Bank statements |
| h3 | Your client's accounts|
diff --git a/features/providers/mtr_accelerated/means_report.feature b/features/providers/mtr_accelerated/means_report.feature
deleted file mode 100644
index e3505d1c06..0000000000
--- a/features/providers/mtr_accelerated/means_report.feature
+++ /dev/null
@@ -1,443 +0,0 @@
-@javascript
-Feature: Means report
-# TODO: AP-5493 - these tests can supercede/replace and be moved to `features/providers/means_report.feature` once mtra switched on and stable
-
- Scenario: For a non-passported, non-TrueLayer application when the client is employed
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed a non-passported employed application with bank statement uploads post-MTRA
- When I view the means report
-
- Then the following sections should exist:
- | tag | section |
- | h2 | Client details |
- | h2 | Proceeding eligibility |
- | h2 | Passported means |
- | h2 | Income result |
- | h2 | Income |
- | h3 | Client employment income |
- | h2 | Outgoings and deductions |
- | h2 | Dependants |
- | h2 | Caseworker Review |
- | h2 | Capital result |
- | h2 | Property, savings and other assets |
- | h3 | Property |
- | h3 | Vehicles |
- | h2 | Bank accounts |
- | h2 | Which savings or investments does your client have? |
- | h2 | Which assets does your client have? |
- | h2 | Restrictions on your client's assets |
- | h2 | Capital disregards |
- | h3 | Bank statements |
-
- Then the following sections should not exist:
- | tag | section |
- | h3 | Your client's accounts |
- | h3 | Client's bank accounts |
-
- Then the following sections should not exist:
- | tag | section |
- | h2 | Declared income categories |
- | h2 | Student finance |
- | h2 | Employed income result |
- | h2 | Declared cash income |
- | h2 | Declared outgoings categories |
- | h2 | Declared cash outgoings |
- | h2 | Payments from scheme or charities |
-
- And the Client details questions should exist:
- | question |
- | First name |
- | Last name |
- | Date of birth |
- | Age at computation date |
- | National Insurance number |
-
- And the Proceeding eligibility questions should exist:
- | question |
- | Extend, variation or discharge - Part IV |
- | Variation or discharge under section 5 protection from harassment act 1997 |
-
- And the Passported means question and answer should match:
- | question | answer |
- | In receipt of passporting benefit | No |
-
- And the Income result questions should exist:
- | question |
- | Total gross income assessed |
- | Total disposable income assessed |
- | Gross income limit |
- | Disposable income lower limit |
- | Disposable income upper limit |
- | Income contribution |
-
- And the Income questions and answers should match:
- | question | answer |
- | Client gross employment income | £2,143.97 |
- | Client income tax | -£204.15 |
- | Client national insurance | -£161.64 |
- | Client fixed employment deduction | -£45 |
- | Client benefits, charitable or government payments | £75 |
- | Client financial help from friends or family | £0 |
- | Client maintenance payments | £0 |
- | Client income from property or lodger | £0 |
- | Client student loan or grant | £0 |
- | Client pension | £0 |
- | Total income | |
-
- And the 'Client' employment notes questions should exist:
- | Do you need to tell us anything else about your client's employment? |
- | Details for client |
-
- And the Outgoings and deductions questions and answers should match:
- | question | answer |
- | Client housing payments (any declared housing benefits have been deducted from this total) | £125 |
- | Client childcare payments | £0 |
- | Client maintenance payments to a former partner | £0 |
- | Client payments towards legal aid in a criminal case | £100 |
- | Dependants allowance | £0 |
- | Total outgoings and deductions | £225 |
-
- And the Dependants questions should exist:
- | question |
- | Does your client have any dependants? |
-
- And the Dependants detail questions should exist:
- | Name |
- | Date of birth |
- | What is their relationship to your client? |
-
- And the Caseworker review section should contain:
- | question | answer |
- | Caseworker review required? | Yes |
- | Review reasons | Restrictions on client's assets |
- | Review reasons | Capital disregards declared |
- | Review reasons | Non-Passported application |
- | Review reasons | Client's further employment details |
- | Review reasons | Client's bank statements uploaded |
-
- And the Capital result questions should exist:
- | question |
- | Total capital assessed |
- | Capital lower limit |
- | Capital upper limit |
- | Capital contribution |
-
- And the Property question should exist:
- | question |
- | Does your client own the home they usually live in? |
-
- And the Property details questions should exist:
- | question |
- | How much is the home they usually live in worth? |
- | How much is left to pay on the mortgage? |
- | Does your client own the home with anyone else? |
- | What percentage of the home does your client legally own? |
-
- And the Vehicle ownership question should exist:
- | question |
- | Does your client own a vehicle? |
-
- And the Vehicles questions should exist:
- | What is the estimated value of the vehicle? |
- | Are there any payments left on the vehicle? |
- | The vehicle was bought more than three years ago? |
- | Is the vehicle in regular use? |
-
- And the "Bank accounts", for static bank account totals, questions should exist:
- | question |
- | Current accounts |
- | Savings accounts |
-
- And the "Which savings or investments does your client have?" questions should exist:
- | question |
- | Money not in a bank account |
- | Access to another person's bank account |
- | ISAs, National Savings Certificates and Premium Bonds |
- | Shares in a PLC |
- | PEPs, unit trusts, capital bonds and government stocks |
- | Life assurance and endowment policies not linked to a mortgage |
-
- And the "Which assets does your client have?" questions should exist:
- | question |
- | Timeshare property |
- | Land |
- | Any valuable items worth £500 or more |
- | Money or assets from the estate of a person who has died |
- | Money owed to them, including from a private mortgage |
- | Interest in a trust |
- | Second property or holiday home estimated value |
- | Second property or holiday home outstanding mortgage amount |
- | Second property or holiday home percentage owned |
-
- And the "Restrictions on your client's assets" questions should exist:
- | question |
- | Is your client banned from selling or borrowing against their assets? |
- | Details of restrictions |
-
- And the Capital disregards questions and answers should match:
- | question | answer |
- | Mandatory disregards | Budgeting Advances\n£1,001 on 8 August 2024\nHeld in Halifax |
- | Discretionary disregards | Compensation, damages or ex-gratia payments for personal harm\nFor: life changing injuries\n£1,002 on 8 August 2024\nHeld in Halifax |
-
- Scenario: For a non-passported truelayer bank transactions journey
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed a non-passported application with truelayer post-MTRA
- When I view the means report
-
- Then the following sections should exist:
- | tag | section |
- | h2 | Client details |
- | h2 | Proceeding eligibility |
- | h2 | Passported means |
- | h2 | Income result |
- | h2 | Income |
- | h3 | Client employment income |
- | h2 | Outgoings and deductions |
- | h2 | Dependants |
- | h2 | Caseworker Review |
- | h2 | Capital result |
- | h2 | Property, savings and other assets |
- | h3 | Property |
- | h3 | Vehicles |
- | h2 | Bank accounts |
- | h3 | Your client's accounts |
- | h2 | Property, savings and other assets |
- | h2 | Which savings or investments does your client have? |
- | h2 | Which assets does your client have? |
- | h2 | Restrictions on your client's assets |
- | h2 | Capital disregards |
- | h2 | Client's bank accounts |
-
- Then the following sections should not exist:
- | tag | section |
- | h2 | Declared income categories |
- | h2 | Student finance |
- | h2 | Employed income result |
- | h2 | Declared cash income |
- | h2 | Declared outgoings categories |
- | h2 | Declared cash outgoings |
- | h2 | Payments from scheme or charities |
- | h3 | Bank statements |
-
- And the Client details questions should exist:
- | question |
- | First name |
- | Last name |
- | Date of birth |
- | Age at computation date |
- | National Insurance number |
-
- And the Proceeding eligibility questions should exist:
- | question |
- | Extend, variation or discharge - Part IV |
- | Variation or discharge under section 5 protection from harassment act 1997 |
-
- And the Passported means question and answer should match:
- | question | answer |
- | In receipt of passporting benefit | No |
-
- And the Income result questions should exist:
- | question |
- | Total gross income assessed |
- | Total disposable income assessed |
- | Gross income limit |
- | Disposable income lower limit |
- | Disposable income upper limit |
- | Income contribution |
-
- And the Income questions and answers should match:
- | question | answer |
- | Client gross employment income | £2,143.97 |
- | Client income tax | -£204.15 |
- | Client national insurance | -£161.64 |
- | Client fixed employment deduction | -£45 |
- | Client benefits, charitable or government payments | £75 |
- | Client financial help from friends or family | £0 |
- | Client maintenance payments | £0 |
- | Client income from property or lodger | £0 |
- | Client student loan or grant | £0 |
- | Client pension | £0 |
- | Total income | |
-
- And the 'Client' employment notes questions should exist:
- | Do you need to tell us anything else about your client's employment? |
- | Details for client |
-
- And the Outgoings and deductions questions and answers should match:
- | question | answer |
- | Client housing payments (any declared housing benefits have been deducted from this total) | £125 |
- | Client childcare payments | £0 |
- | Client maintenance payments to a former partner | £0 |
- | Client payments towards legal aid in a criminal case | £100 |
- | Dependants allowance | £0 |
- | Total outgoings and deductions | £225 |
-
- And the Dependants questions should exist:
- | question |
- | Does your client have any dependants? |
-
- And the Dependants detail questions should exist:
- | Name |
- | Date of birth |
- | What is their relationship to your client? |
-
- And the Caseworker review section should contain:
- | question | answer |
- | Caseworker review required? | Yes |
- | Review reasons | Restrictions on client's assets |
- | Review reasons | Capital disregards declared |
- | Review reasons | Non-Passported application |
- | Review reasons | Client's further employment details |
-
- And the Capital result questions should exist:
- | question |
- | Total capital assessed |
- | Capital lower limit |
- | Capital upper limit |
- | Capital contribution |
-
- And the Property question should exist:
- | question |
- | Does your client own the home they usually live in? |
-
- And the Property details questions should exist:
- | question |
- | How much is the home they usually live in worth? |
- | How much is left to pay on the mortgage? |
- | Does your client own the home with anyone else? |
- | What percentage of the home does your client legally own? |
-
- And the Vehicle ownership question should exist:
- | question |
- | Does your client own a vehicle? |
-
- And the Vehicles questions should exist:
- | What is the estimated value of the vehicle? |
- | Are there any payments left on the vehicle? |
- | The vehicle was bought more than three years ago? |
- | Is the vehicle in regular use? |
-
- And the "Bank accounts", for open banking accounts, questions should exist:
- | question |
- | Current accounts |
- | Savings accounts |
-
- And the "Bank accounts", for open banking accounts, questions and answers table should exist:
- | question | answer |
- | Account Name, 12345678, 000000 | £75.57 |
- | Second Account, 87654321, 999999 | £57.57 |
-
- And the "Your client's accounts" questions should exist:
- | question |
- | Has savings accounts they cannot access online |
- | Amount in offline savings accounts |
-
- And the "Which savings or investments does your client have?" questions should exist:
- | question |
- | Money not in a bank account |
- | Access to another person's bank account |
- | ISAs, National Savings Certificates and Premium Bonds |
- | Shares in a PLC |
- | PEPs, unit trusts, capital bonds and government stocks |
- | Life assurance and endowment policies not linked to a mortgage |
-
- And the "Which assets does your client have?" questions should exist:
- | question |
- | Timeshare property |
- | Land |
- | Any valuable items worth £500 or more |
- | Money or assets from the estate of a person who has died |
- | Money owed to them, including from a private mortgage |
- | Interest in a trust |
- | Second property or holiday home estimated value |
- | Second property or holiday home outstanding mortgage amount |
- | Second property or holiday home percentage owned |
-
- And the "Restrictions on your client's assets" questions should exist:
- | question |
- | Is your client banned from selling or borrowing against their assets? |
- | Details of restrictions |
-
- And the Capital disregards questions and answers should match:
- | question | answer |
- | Mandatory disregards | Budgeting Advances\n£1,001 on 8 August 2024\nHeld in Halifax |
- | Discretionary disregards | Compensation, damages or ex-gratia payments for personal harm\nFor: life changing injuries\n£1,002 on 8 August 2024\nHeld in Halifax |
-
- Scenario: For a passported journey
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed a passported application post-MTRA
- When I view the means report
-
- Then the following sections should exist:
- | tag | section |
- | h2 | Client details |
- | h2 | Proceeding eligibility |
- | h2 | Passported means |
- | h2 | Capital result |
- | h2 | Property, savings and other assets |
- | h3 | Property |
- | h3 | Vehicles |
- | h2 | Bank accounts |
- | h2 | Which savings or investments does your client have? |
- | h2 | Which assets does your client have? |
- | h2 | Restrictions on your client's assets |
- | h2 | Capital disregards |
- | h2 | Caseworker Review |
-
- Then the following sections should not exist:
- | tag | section |
- | h2 | Income result |
- | h2 | Income |
- | h2 | Employed income result |
- | h2 | Outgoings and deductions |
- | h2 | Declared income categories |
- | h2 | Student finance |
- | h2 | Declared cash income |
- | h2 | Dependants |
- | h2 | Declared outgoings categories |
- | h2 | Declared cash outgoings |
- | h2 | Payments from scheme or charities |
- | h3 | Bank statements |
-
- And the Passported means question and answer should match:
- | question | answer |
- | In receipt of passporting benefit | Yes |
-
- Scenario: For a non means tested journey
- Given I have completed a non means tested application
- When I view the means report
-
- Then the following sections should exist:
- | tag | section |
- | h2 | Client details |
-
- Then the following sections should not exist:
- | tag | section |
- | h2 | Proceeding eligibility |
- | h2 | Passported means |
- | h2 | Income result |
- | h2 | Income |
- | h3 | Client employment income |
- | h2 | Outgoings |
- | h2 | Deductions |
- | h2 | Caseworker Review |
- | h2 | Capital result |
- | h2 | Property, savings and other assets |
- | h3 | Property |
- | h3 | Vehicles |
- | h2 | Bank accounts |
- | h2 | Which savings or investments does your client have? |
- | h2 | Which assets does your client have? |
- | h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
- | h2 | Capital disregards |
- | h3 | Bank statements |
- | h3 | Your client's accounts|
-
- And the "Client details" check your answers section should contain:
- | question | answer |
- | Age at computation date | 17 years old |
- | Was the client means-tested? | No |
diff --git a/features/step_definitions/means_report_steps.rb b/features/step_definitions/means_report_steps.rb
index 23fbbfa626..2517057db7 100644
--- a/features/step_definitions/means_report_steps.rb
+++ b/features/step_definitions/means_report_steps.rb
@@ -1,53 +1,4 @@
-# TODO: AP-5493 - can be deleted post-MTRA
Given(/^I have completed a non-passported (employed|employed with partner) application with bank statement uploads$/) do |optional_partner|
- @legal_aid_application = create(
- :legal_aid_application,
- :with_proceedings,
- :with_employed_applicant_and_extra_info,
- :with_non_passported_state_machine,
- :with_vehicle,
- :with_transaction_period,
- :with_rent_or_mortgage_regular_transaction,
- :with_housing_benefit_regular_transaction,
- :with_other_assets_declaration,
- :with_policy_disregards,
- :with_restrictions,
- :with_fixed_offline_accounts,
- :with_dependant,
- :with_own_home_mortgaged,
- :with_merits_statement_of_case,
- :with_opponent,
- :with_incident,
- :with_parties_mental_capacity,
- :with_domestic_abuse_summary,
- :with_chances_of_success,
- :assessment_submitted,
- property_value: 599_999.99,
- outstanding_mortgage_amount: 399_999.99,
- shared_ownership: "partner_or_ex_partner",
- percentage_home: 33.33,
- explicit_proceedings: %i[da002 da006],
- set_lead_proceeding: :da002,
- provider_received_citizen_consent: false,
- attachments: [build(:attachment, :bank_statement)],
- )
-
- create :legal_framework_merits_task_list, :da002_da006_as_applicant, legal_aid_application: @legal_aid_application
-
- cfe_submission = create(:cfe_submission, legal_aid_application: @legal_aid_application)
- if optional_partner == "employed with partner"
- create(:cfe_v6_result, :with_partner, submission: cfe_submission, legal_aid_application: @legal_aid_application)
- create(:partner, :with_extra_employment_information, legal_aid_application: @legal_aid_application)
- @legal_aid_application.applicant.update!(has_partner: true, partner_has_contrary_interest: false)
- else
- create(:cfe_v6_result, submission: cfe_submission, legal_aid_application: @legal_aid_application)
- end
-
- login_as @legal_aid_application.provider
-end
-
-# TODO: AP-5493 - can be renamed to remove the post-MTRA, post MTRA
-Given(/^I have completed a non-passported (employed|employed with partner) application with bank statement uploads post-MTRA$/) do |optional_partner|
@legal_aid_application = create(
:legal_aid_application,
:with_proceedings,
@@ -95,74 +46,7 @@
login_as @legal_aid_application.provider
end
-# TODO: can be deleted post MTRA
Given(/^I have completed a (non-passported|non-passported with partner) application with truelayer$/) do |optional_partner|
- bank_provider = create(:bank_provider)
- create(
- :bank_account,
- bank_provider:,
- name: "Account Name",
- account_number: "12345678",
- sort_code: "000000",
- balance: "75.57",
- )
- create(
- :bank_account,
- bank_provider:,
- name: "Second Account",
- account_number: "87654321",
- sort_code: "999999",
- balance: "57.57",
- )
- @legal_aid_application = create(
- :legal_aid_application,
- :with_proceedings,
- :with_employed_applicant_and_extra_info,
- :with_non_passported_state_machine,
- :with_restrictions,
- :with_vehicle,
- :with_transaction_period,
- :with_other_assets_declaration,
- :with_policy_disregards,
- :with_savings_amount,
- :with_open_banking_consent,
- :with_consent,
- :with_dependant,
- :with_cfe_v6_result,
- :with_own_home_mortgaged,
- :with_merits_statement_of_case,
- :with_incident,
- :with_opponent,
- :with_parties_mental_capacity,
- :with_domestic_abuse_summary,
- :with_chances_of_success,
- :assessment_submitted,
- property_value: 599_999.99,
- outstanding_mortgage_amount: 399_999.99,
- shared_ownership: "partner_or_ex_partner",
- percentage_home: 33.33,
- explicit_proceedings: %i[da002 da006],
- set_lead_proceeding: :da002,
- )
-
- @legal_aid_application.applicant.update!(bank_providers: [bank_provider])
-
- create :legal_framework_merits_task_list, :da002_da006_as_applicant, legal_aid_application: @legal_aid_application
-
- cfe_submission = create(:cfe_submission, legal_aid_application: @legal_aid_application)
- if optional_partner == "non-passported with partner"
- create(:cfe_v6_result, :with_partner, submission: cfe_submission, legal_aid_application: @legal_aid_application)
- create(:partner, :with_extra_employment_information, legal_aid_application: @legal_aid_application)
- @legal_aid_application.applicant.update!(has_partner: true, partner_has_contrary_interest: false)
- else
- create(:cfe_v6_result, submission: cfe_submission, legal_aid_application: @legal_aid_application)
- end
-
- login_as @legal_aid_application.provider
-end
-
-# TODO: AP-5493 can be renamed to remove the post-MTRA, post MTRA
-Given(/^I have completed a (non-passported|non-passported with partner) application with truelayer post-MTRA$/) do |optional_partner|
bank_provider = create(:bank_provider)
create(
:bank_account,
@@ -228,41 +112,7 @@
login_as @legal_aid_application.provider
end
-# TODO: can be deleted post MTRA
Given("I have completed a passported application") do
- @legal_aid_application = create(
- :legal_aid_application,
- :with_proceedings,
- :with_applicant_and_address,
- :with_passported_state_machine,
- :with_savings_amount,
- :with_restrictions,
- :with_vehicle,
- :with_transaction_period,
- :with_other_assets_declaration,
- :with_policy_disregards,
- :with_savings_amount,
- :with_cfe_v5_result,
- :with_own_home_mortgaged,
- :with_merits_statement_of_case,
- :with_opponent,
- :with_incident,
- :with_chances_of_success,
- :assessment_submitted,
- provider_received_citizen_consent: true,
- property_value: 599_999.99,
- outstanding_mortgage_amount: 399_999.99,
- shared_ownership: "partner_or_ex_partner",
- percentage_home: 33.33,
- explicit_proceedings: %i[da002 da006],
- set_lead_proceeding: :da002,
- )
-
- login_as @legal_aid_application.provider
-end
-
-# TODO: AP-5493 - can be renamed to remove the post-MTRA, post MTRA
-Given("I have completed a passported application post-MTRA") do
@legal_aid_application = create(
:legal_aid_application,
:with_proceedings,
From a3f7ab518a81de272ab33805d9262da0b4e03808 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Mon, 9 Dec 2024 17:08:24 +0000
Subject: [PATCH 10/20] AP-5383: Move check_capital_answers feature out of
MTR2A folder
Update / remove references to MTR2A
---
.../check_capital_answers.feature | 15 ++------
.../check_your_answers_steps.rb | 38 +------------------
2 files changed, 5 insertions(+), 48 deletions(-)
rename features/providers/{mtr_accelerated => }/check_capital_answers.feature (86%)
diff --git a/features/providers/mtr_accelerated/check_capital_answers.feature b/features/providers/check_capital_answers.feature
similarity index 86%
rename from features/providers/mtr_accelerated/check_capital_answers.feature
rename to features/providers/check_capital_answers.feature
index 451754b12e..44478e5daa 100644
--- a/features/providers/mtr_accelerated/check_capital_answers.feature
+++ b/features/providers/check_capital_answers.feature
@@ -1,13 +1,8 @@
@javascript
Feature: Check capital income answers
-# TODO: AP-5493 - these tests can be moved to the `feaures/providers/` folder once mtra switched on and stable
-# They can provide a basis for a feature test suite for excercisng the various check your answer pages and flows
-#
Scenario: For a non-passported, bank statement upload journey
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed the income and capital sections of a non-passported application with bank statement uploads post-MTRA
+ Given I have completed the income and capital sections of a non-passported application with bank statement uploads
When I am viewing the means capital check your answers page
Then the following sections should exist:
@@ -54,9 +49,7 @@ Feature: Check capital income answers
| Bank account | Halifax |
Scenario: For a non-passported truelayer bank transactions journey
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed the income and capital sections of a non-passported application with open banking transactions post-MTRA
+ Given I have completed the income and capital sections of a non-passported application with open banking transactions
When I am viewing the means capital check your answers page
Then the following sections should exist:
@@ -103,9 +96,7 @@ Feature: Check capital income answers
| Bank account | Halifax |
Scenario: For a passported journey
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed the capital sections of passported application post-MTRA
+ Given I have completed the capital sections of passported application
When I am viewing the passported capital check your answers page
Then the following sections should exist:
diff --git a/features/step_definitions/check_your_answers_steps.rb b/features/step_definitions/check_your_answers_steps.rb
index a3a58a5a27..107d5e230d 100644
--- a/features/step_definitions/check_your_answers_steps.rb
+++ b/features/step_definitions/check_your_answers_steps.rb
@@ -29,40 +29,6 @@
end
Given("I have completed the income and capital sections of a non-passported application with open banking transactions") do
- @legal_aid_application = create(
- :legal_aid_application,
- :with_proceedings,
- :with_employed_applicant,
- :with_non_passported_state_machine,
- :with_fixed_offline_savings_accounts,
- :with_restrictions,
- :with_maintenance_in_category,
- :with_fixed_benefits_transactions,
- :with_fixed_benefits_cash_transactions,
- :with_maintenance_in_category,
- :with_fixed_rent_or_mortage_transactions,
- :with_fixed_rent_or_mortage_cash_transactions,
- :with_maintenance_out_category,
- :with_transaction_period,
- :with_policy_disregards,
- :with_open_banking_consent,
- :with_consent,
- :with_dependant,
- :with_own_home_mortgaged,
- :checking_non_passported_means,
- property_value: rand(1...1_000_000.0).round(2),
- outstanding_mortgage_amount: rand(1...1_000_000.0).round(2),
- shared_ownership: LegalAidApplication::SHARED_OWNERSHIP_YES_REASONS.sample,
- percentage_home: rand(1...99.0).round(2),
- explicit_proceedings: %i[da002 da006],
- set_lead_proceeding: :da002,
- )
- create :employment, legal_aid_application: @legal_aid_application, owner_id: @legal_aid_application.applicant.id, owner_type: "Applicant"
-
- login_as @legal_aid_application.provider
-end
-
-Given("I have completed the income and capital sections of a non-passported application with open banking transactions post-MTRA") do
@legal_aid_application = create(
:legal_aid_application,
:with_proceedings,
@@ -103,7 +69,7 @@
login_as @legal_aid_application.provider
end
-Given("I have completed the income and capital sections of a non-passported application with bank statement uploads post-MTRA") do
+Given("I have completed the income and capital sections of a non-passported application with bank statement uploads") do
@legal_aid_application = create(
:legal_aid_application,
:with_proceedings,
@@ -136,7 +102,7 @@
login_as @legal_aid_application.provider
end
-Given("I have completed the capital sections of passported application post-MTRA") do
+Given("I have completed the capital sections of passported application") do
@legal_aid_application = create(
:legal_aid_application,
:with_proceedings,
From ddd45aa2812f03772443493b4d7cee33badbafcc Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Tue, 10 Dec 2024 09:09:37 +0000
Subject: [PATCH 11/20] AP-5383: Remove now unused feature file
Remove feature tests for functionality that no longer exists
---
.../mtr_accelerated/disregard_list.feature | 63 -------------------
1 file changed, 63 deletions(-)
delete mode 100644 features/providers/mtr_accelerated/disregard_list.feature
diff --git a/features/providers/mtr_accelerated/disregard_list.feature b/features/providers/mtr_accelerated/disregard_list.feature
deleted file mode 100644
index 356fb947b3..0000000000
--- a/features/providers/mtr_accelerated/disregard_list.feature
+++ /dev/null
@@ -1,63 +0,0 @@
-Feature: Disregarded benefits list changes for MTR-Accelerated measures
-# TODO: AP-5493 - This whole file can probably be deleted after the MTR-A feature flag is removed
-
- @javascript
- Scenario: When the MTR-A feature flag is off I should see the legacy disregard list
- Given the feature flag for means_test_review_a is disabled
- And I have completed a non-passported non-employed application for "applicant" with bank statements as far as the end of the means income section
- Then I should be on the "check_income_answers" page showing "Check your answers"
-
- When I click Check Your Answers Change link for applicant 'state_benefits'
- Then I should see govuk-details 'What not to include'
-
- When I open the section 'What not to include'
- Then the following sections should exist:
- | tag | section |
- | h2 | Government Cost of Living Payments |
- | h2 | Disregarded benefits |
- | h3 | Carer and disability benefits |
- | h3 | Low income benefits |
- | h3 | Other benefits |
-
- Then I should see 'They are known as mandatory disregards'
- And I should see 'Benefit Transfer Advance \(Universal Credit\)'
- And I should see 'Council Tax Reduction'
- And I should see 'Earnings Top-up \(ETU\)'
- And I should see 'Widow's Pension lump sum payments'
-
- And I should not see 'Universal Credit advance payments'
- And I should not see 'Compensation for miscarriage of justice'
- And I should not see 'Infected Blood Support Scheme'
- And I should not see 'Modern Slavery'
- And I should not see 'Scotland and Northern Ireland Redress Schemes'
-
- @javascript
- Scenario: When the MTR-A feature flag is on I should see the MTR-A disregard list
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed a non-passported non-employed application for "applicant" with bank statements as far as the end of the means income section
- Then I should be on the "check_income_answers" page showing "Check your answers"
-
- When I click Check Your Answers Change link for applicant 'state_benefits'
- Then I should see govuk-details 'What not to include'
-
- When I open the section 'What not to include'
- Then the following sections should exist:
- | tag | section |
- | h2 | Government Cost of Living Payments |
- | h2 | Disregarded benefits and payments |
- | h3 | Carer and disability |
- | h3 | Low income |
- | h3 | Other |
-
- Then I should see 'They are known as mandatory disregards'
- And I should not see 'Benefit Transfer Advance'
- And I should not see 'Council Tax Reduction'
- And I should not see 'Earnings Top-up'
- And I should not see 'Widow's Pension'
-
- And I should see 'Universal Credit advance payments'
- And I should see 'Compensation for miscarriage of justice'
- And I should see 'Infected Blood Support Scheme\nIncludes Infected Blood Interim Compensation Payment Scheme, Infected Blood Further Interim Compensation Scheme, Infected Blood Compensation Scheme, arrangements made under section 56\(1\) of the Victims and Prisoners Act 2024 or earlier support schemes'
- And I should see 'Modern Slavery Victim Care Contract \(MSVCC\) payments'
- And I should see 'Scotland and Northern Ireland Redress Schemes for historical child abuse payment'
From 3949bd82fc7e0ba43e8bf427fc69f6128888e524 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Tue, 10 Dec 2024 09:32:14 +0000
Subject: [PATCH 12/20] AP-5383: Remove feature tests that are no longer needed
Remove feature tests that test scenarios for when MTR2A flag is off.
Remaining tidy up will be done as part of AP-5493.
---
.../capital_disregards.feature | 40 +----------
.../mtr_accelerated/main_dwelling.feature | 66 -------------------
2 files changed, 1 insertion(+), 105 deletions(-)
diff --git a/features/providers/mtr_accelerated/capital_disregards.feature b/features/providers/mtr_accelerated/capital_disregards.feature
index f4dc49aa2c..86d4da2794 100644
--- a/features/providers/mtr_accelerated/capital_disregards.feature
+++ b/features/providers/mtr_accelerated/capital_disregards.feature
@@ -1,47 +1,9 @@
Feature: mandatory and discretionary capital disregards questions and flow
# TODO: AP-5493 - This flow file can be moved to a full flow non-passported journey feature after the MTR-A feature flag is removed
- @javascript
- Scenario: When the MTR-A feature flag is off I should not see the mandatory or discretionary capital disregard questions in the flow
- Given the feature flag for means_test_review_a is disabled
- And I have completed a non-passported non-employed application for "applicant" with bank statements as far as the end of the means income section
- Then I should be on the "check_income_answers" page showing "Check your answers"
-
- When I click "Save and continue"
- Then I should be on a page with title "What you need to do"
-
- When I click "Continue"
- Then I should be on a page with title "Does your client own the home that they live in?"
- And I choose 'No'
-
- When I click "Save and continue"
- Then I should be on a page with title "Does your client own a vehicle?"
- And I choose 'No'
-
- When I click "Save and continue"
- Then I should be on a page with title "Which bank accounts does your client have?"
- And I select "None of these"
-
- When I click "Save and continue"
- Then I should be on a page with title "Which savings or investments does your client have?"
- And I select "None of these savings or investments"
-
- When I click "Save and continue"
- Then I should be on a page with title "Which assets does your client have?"
- And I select "None of these assets"
-
- When I click "Save and continue"
- Then I should be on a page with title "Which schemes or trusts have paid your client?"
- And I select "None of these schemes or trusts"
-
- When I click "Save and continue"
- Then I should be on the "check_capital_answers" page showing "Check your answers"
-
@javascript
Scenario: When the MTR-A feature flag is on I should see the mandatory and discretionary capital disregard question in the flow
- Given the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
- And I have completed a non-passported non-employed application for "applicant" with bank statements as far as the end of the means income section
+ Given I have completed a non-passported non-employed application for "applicant" with bank statements as far as the end of the means income section
Then I should be on the "check_income_answers" page showing "Check your answers"
When I click "Save and continue"
diff --git a/features/providers/mtr_accelerated/main_dwelling.feature b/features/providers/mtr_accelerated/main_dwelling.feature
index 7256726947..81e95784a9 100644
--- a/features/providers/mtr_accelerated/main_dwelling.feature
+++ b/features/providers/mtr_accelerated/main_dwelling.feature
@@ -1,73 +1,9 @@
Feature: Main dwelling place changes for MTR-Accelerated measures
# TODO: AP-5493 - This whole file can probably be deleted after the MTR-A feature flag is removed
- @javascript
- Scenario: When the MTR-A feature flag is off and the client has no partner I should see the legacy pages
- Given I previously created a passported application with no assets and left on the "check_passported_answers" page
- And the feature flag for means_test_review_a is disabled
-
- When I visit the in progress applications page
- And I view the previously created application
- Then I am on the check your answers page for other assets
-
- When I click Check Your Answers Change link for 'own_home'
- Then I should be on a page showing "Does your client own the home that they live in?"
- And I should not see "This is where your client normally lives, even if they have temporarily left their home due to domestic abuse."
-
- When I choose "Yes, with a mortgage or loan"
- Then I click "Save and continue"
- Then I should be on a page showing "Your client's home"
- And I should see "How much is the home your client lives in worth?"
-
- When I click link 'Back'
- And I choose "Yes, owned outright"
- Then I click "Save and continue"
- Then I should be on a page showing "Your client's home"
- And I should see "How much is the home your client lives in worth?"
-
- @javascript
- Scenario: When the MTR-A feature flag is off and the client a partner I should see the legacy pages
- Given I complete the journey as far as check client details with a partner
- And the feature flag for means_test_review_a is disabled
-
- When I click "Save and continue"
- Then I should be on a page with title "DWP records show that your client does not get a passporting benefit"
-
- When I choose "No, my client gets a joint passporting benefit with their partner"
- And I click "Save and continue"
- Then I should be on a page with title "Check your client's and their partner's details"
-
- When I click "Save and continue"
- Then I should be on a page with title "Which joint passporting benefit does your client and their partner get?"
-
- When I choose "Universal Credit"
- And I click "Save and continue"
- Then I should be on a page with title "Do you have evidence that your client is covered by their partner's Universal Credit?"
-
- When I choose "Yes"
- And I click "Save and continue"
- Then I should be on a page with title "What you need to do"
-
- When I click "Continue"
- Then I should be on a page with title "Does your client or their partner own the home your client lives in?"
- And I should not see "This is where your client normally lives, even if they have temporarily left their home due to domestic abuse."
-
- When I choose "Yes, with a mortgage or loan"
- Then I click "Save and continue"
- Then I should be on a page showing "Your client's home"
- And I should see "How much is the home your client and their partner live in worth?"
-
- When I click link 'Back'
- And I choose "Yes, owned outright"
- Then I click "Save and continue"
- Then I should be on a page showing "Your client's home"
- And I should see "How much is the home your client and their partner live in worth?"
-
@javascript
Scenario: When the MTR-A feature flag is on and the client has no partner I should see the legacy pages
Given I previously created a passported application with no assets and left on the "check_passported_answers" page
- And the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
When I visit the in progress applications page
And I view the previously created application
@@ -91,8 +27,6 @@ Feature: Main dwelling place changes for MTR-Accelerated measures
@javascript
Scenario: When the MTR-A feature flag is on and the client a partner I should see the legacy pages
Given I complete the journey as far as check client details with a partner
- And the feature flag for means_test_review_a is enabled
- And the MTR-A start date is in the past
When I click "Save and continue"
Then I should be on a page with title "DWP records show that your client does not get a passporting benefit"
From 9f1a6d9f7298ad8daffbe49370a8a4a59a26f3b7 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Tue, 10 Dec 2024 09:33:05 +0000
Subject: [PATCH 13/20] AP-5383: Remove debug step for MTR-A flag as no longer
needed
---
features/step_definitions/debug_steps.rb | 5 -----
1 file changed, 5 deletions(-)
diff --git a/features/step_definitions/debug_steps.rb b/features/step_definitions/debug_steps.rb
index 8b6438d632..bcceeb6209 100644
--- a/features/step_definitions/debug_steps.rb
+++ b/features/step_definitions/debug_steps.rb
@@ -23,11 +23,6 @@
@registered_provider.firm.permissions << sca_permission
end
-And(/^the MTR-A start date is in the past$/) do
- # TODO: Remove when removing Setting.means_test_review_a
- allow(Rails.configuration.x).to receive(:mtr_a_start_date).and_return(Date.yesterday)
-end
-
When(/^I sleep for (.*?) seconds$/) do |num_secs|
sleep num_secs.to_i
end
From 690ca54d5229826ec90641eaacf5b4765d9d3ceb Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Tue, 10 Dec 2024 09:41:05 +0000
Subject: [PATCH 14/20] AP-5383: Add migration to remove mtr a column from
database
---
...41212085816_remove_means_test_review_a_from_settings.rb | 7 +++++++
db/schema.rb | 3 +--
2 files changed, 8 insertions(+), 2 deletions(-)
create mode 100644 db/migrate/20241212085816_remove_means_test_review_a_from_settings.rb
diff --git a/db/migrate/20241212085816_remove_means_test_review_a_from_settings.rb b/db/migrate/20241212085816_remove_means_test_review_a_from_settings.rb
new file mode 100644
index 0000000000..fc9c1373d5
--- /dev/null
+++ b/db/migrate/20241212085816_remove_means_test_review_a_from_settings.rb
@@ -0,0 +1,7 @@
+class RemoveMeansTestReviewAFromSettings < ActiveRecord::Migration[7.2]
+ def change
+ safety_assured do
+ remove_column :settings, :means_test_review_a, :boolean, null: false, default: false
+ end
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index e0c966e58c..dd7cbecee8 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.
-ActiveRecord::Schema[7.2].define(version: 2024_12_11_093840) do
+ActiveRecord::Schema[7.2].define(version: 2024_12_12_085816) do
# These are extensions that must be enabled in order to support this database
enable_extension "pgcrypto"
enable_extension "plpgsql"
@@ -1015,7 +1015,6 @@
t.boolean "linked_applications", default: false, null: false
t.boolean "collect_hmrc_data", default: false, null: false
t.boolean "special_childrens_act", default: false, null: false
- t.boolean "means_test_review_a", default: false, null: false
t.boolean "public_law_family", default: false, null: false
end
From f072732d78d56bad5a2c954d174c8d6979f9b099 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Wed, 11 Dec 2024 12:10:58 +0000
Subject: [PATCH 15/20] AP-5383: Update feature tests to reflect post MTR-A
content
---
features/providers/back_button.feature | 4 ++--
.../providers/check_ccms_autogrant.feature | 18 +++++++++++------
.../check_multiple_employment.feature | 10 +++++++---
.../check_nonpassport_autogrant.feature | 20 ++++++++++++-------
.../check_pending_employment.feature | 10 +++++++---
.../providers/check_single_employment.feature | 10 +++++++---
features/providers/check_your_answers.feature | 10 +++++-----
.../complete_and_check_means_answers.feature | 2 +-
.../with_capital.feature | 2 +-
.../with_dependants.feature | 4 ++--
.../non_passported_journey/with_means.feature | 2 +-
.../end_to_end_capital_assessment.feature | 4 ++--
features/providers/passported_journey.feature | 6 +++---
13 files changed, 63 insertions(+), 39 deletions(-)
diff --git a/features/providers/back_button.feature b/features/providers/back_button.feature
index bcb73ecdb1..aa6da14166 100644
--- a/features/providers/back_button.feature
+++ b/features/providers/back_button.feature
@@ -10,7 +10,7 @@
# Then I click 'Continue'
# Then I should be on a page showing "Before you continue"
# Then I click 'Save and continue'
-# Then I should be on a page showing "Does your client own the home that they live in?"
+# Then I should be on a page showing "Does your client own the home they usually live in?"
# Then I choose "Yes, with a mortgage or loan"
# Then I click 'Save and continue'
# Then I should be on a page showing "How much is your client's home worth?"
@@ -69,7 +69,7 @@
# Then I click link "Back"
# Then I should be on a page showing "How much is your client's home worth?"
# Then I click link "Back"
-# Then I should be on a page showing "Does your client own the home that they live in?"
+# Then I should be on a page showing "Does your client own the home they usually live in?"
# Then I click 'Save and continue'
# Then I click 'Save and continue'
# Then I click 'Save and continue'
diff --git a/features/providers/check_ccms_autogrant.feature b/features/providers/check_ccms_autogrant.feature
index c5aa178acb..13c70af4a1 100644
--- a/features/providers/check_ccms_autogrant.feature
+++ b/features/providers/check_ccms_autogrant.feature
@@ -16,9 +16,12 @@ Feature: Checking ccms means does NOT auto grant
Then I should be on a page showing "Is your client banned from selling or borrowing against their assets?"
Then I choose "No"
And I click 'Save and continue'
- Then I should be on a page showing "Which schemes or trusts have paid your client?"
- Then I check "None of these schemes or trusts"
- Then I click 'Save and continue'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I should be on a page showing 'Check your answers'
And I should be on a page showing 'Money not in a bank account'
And I should be on a page showing '£4,000'
@@ -91,9 +94,12 @@ Feature: Checking ccms means does NOT auto grant
Then I am on the "Which assets does your client have?" page
Then I check "None of these assets"
Then I click 'Save and continue'
- Then I am on the "Which schemes or trusts have paid your client?" page
- Then I check "None of these schemes or trusts"
- Then I click 'Save and continue'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I am on the "Check your answers" page
Then I click 'Save and continue'
And I should be on a page showing "could be eligible for legal aid"
diff --git a/features/providers/check_multiple_employment.feature b/features/providers/check_multiple_employment.feature
index 0efc23fcaf..42d9d6d671 100644
--- a/features/providers/check_multiple_employment.feature
+++ b/features/providers/check_multiple_employment.feature
@@ -64,7 +64,7 @@ Feature: Check multiple employment
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
When I choose "No"
And I click 'Save and continue'
@@ -88,9 +88,13 @@ Feature: Check multiple employment
When I choose "No"
And I click 'Save and continue'
- Then I should be on a page showing "Which schemes or trusts have paid your client?"
+ Then I should be on a page showing "Disregarded payments"
- When I check "None of these schemes or trusts"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
diff --git a/features/providers/check_nonpassport_autogrant.feature b/features/providers/check_nonpassport_autogrant.feature
index 494cfdc674..e56f1cd123 100644
--- a/features/providers/check_nonpassport_autogrant.feature
+++ b/features/providers/check_nonpassport_autogrant.feature
@@ -50,7 +50,7 @@ Feature: Checking ccms means does NOT auto grant for non passported applications
Then I should be on a page with title "What you need to do"
And I should see "Tell us about your client's capital"
When I click "Continue"
- Then I am on the "Does your client own the home that they live in?" page
+ Then I am on the "Does your client own the home they usually live in?" page
Then I choose "legal-aid-application-own-home-no-field"
Then I click 'Save and continue'
Then I am on the "Does your client own a vehicle?" page
@@ -69,8 +69,11 @@ Feature: Checking ccms means does NOT auto grant for non passported applications
Then I am on the "Is your client banned from selling or borrowing against their assets?" page
Then I choose "No"
Then I click 'Save and continue'
- Then I am on the "Which schemes or trusts have paid your client?" page
- Then I check "policy-disregards-none-selected-true-field"
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
Then I click 'Save and continue'
Then I am on the "Check your answers" page
Then I click 'Save and continue'
@@ -182,7 +185,7 @@ Feature: Checking ccms means does NOT auto grant for non passported applications
Then I should be on a page with title "What you need to do"
And I should see "Tell us about your client's capital"
Then I click 'Continue'
- Then I am on the "Does your client own the home that they live in?" page
+ Then I am on the "Does your client own the home they usually live in?" page
Then I choose "legal-aid-application-own-home-no-field"
Then I click 'Save and continue'
Then I am on the "Does your client own a vehicle?" page
@@ -201,9 +204,12 @@ Feature: Checking ccms means does NOT auto grant for non passported applications
Then I am on the "Is your client banned from selling or borrowing against their assets?" page
Then I choose "No"
Then I click 'Save and continue'
- Then I am on the "Which schemes or trusts have paid your client?" page
- Then I check "policy-disregards-none-selected-true-field"
- Then I click 'Save and continue'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I am on the "Check your answers" page
Then I click 'Save and continue'
Then I am on the "may need to pay towards legal aid" page
diff --git a/features/providers/check_pending_employment.feature b/features/providers/check_pending_employment.feature
index b97335231f..1e4a71cd5c 100644
--- a/features/providers/check_pending_employment.feature
+++ b/features/providers/check_pending_employment.feature
@@ -61,7 +61,7 @@ Feature: Check pending employment
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
When I choose "No"
And I click 'Save and continue'
@@ -85,9 +85,13 @@ Feature: Check pending employment
When I choose "No"
And I click 'Save and continue'
- Then I should be on a page showing "Which schemes or trusts have paid your client?"
+ Then I should be on a page showing "Disregarded payments"
- When I check "None of these schemes or trusts"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
diff --git a/features/providers/check_single_employment.feature b/features/providers/check_single_employment.feature
index dc18ada31e..9a0d91a8db 100644
--- a/features/providers/check_single_employment.feature
+++ b/features/providers/check_single_employment.feature
@@ -61,7 +61,7 @@ Feature: Check single employment
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
When I choose "No"
And I click 'Save and continue'
@@ -84,9 +84,13 @@ Feature: Check single employment
When I choose "No"
And I click 'Save and continue'
- Then I should be on a page showing "Which schemes or trusts have paid your client?"
+ Then I should be on a page showing "Disregarded payments"
- When I check "None of these schemes or trusts"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on a page showing "Check your answers"
diff --git a/features/providers/check_your_answers.feature b/features/providers/check_your_answers.feature
index 4d84246233..01b65aca5d 100644
--- a/features/providers/check_your_answers.feature
+++ b/features/providers/check_your_answers.feature
@@ -7,7 +7,7 @@ Feature: Checking answers backwards and forwards
Then I view the previously created application
Then I am on the check your answers page for other assets
And I click Check Your Answers Change link for 'own_home'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "Yes, with a mortgage or loan"
Then I click 'Save and continue'
Then I should be on a page showing "Your client's home"
@@ -35,7 +35,7 @@ Feature: Checking answers backwards and forwards
Then I view the previously created application
Then I am on the check your answers page for other assets
And I click Check Your Answers Change link for 'own_home'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "Yes, with a mortgage or loan"
Then I click 'Save and continue'
Then I should be on a page showing "Your client's home"
@@ -63,7 +63,7 @@ Feature: Checking answers backwards and forwards
Then I view the previously created application
Then I am on the check your answers page for other assets
And I click Check Your Answers Change link for 'own_home'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I click 'Save and continue'
Then I am on the check your answers page for other assets
And the answer for 'Own home' should be 'No'
@@ -183,7 +183,7 @@ Feature: Checking answers backwards and forwards
Scenario: I want to change property value via the capital check your answers page
Given I complete the passported journey as far as capital check your answers
And I click Check Your Answers Change link for 'Own home'
- Then I should be on a page showing 'Does your client own the home that they live in?'
+ Then I should be on a page showing 'Does your client own the home they usually live in?'
Then I click 'Save and continue'
Then I should be on a page showing "Your client's home"
Then I fill 'Property value' with '500000'
@@ -198,7 +198,7 @@ Feature: Checking answers backwards and forwards
Scenario: I want to remove property details via the capital check your answers page
Given I complete the passported journey as far as capital check your answers
And I click Check Your Answers Change link for 'Own home'
- Then I should be on a page showing 'Does your client own the home that they live in?'
+ Then I should be on a page showing 'Does your client own the home they usually live in?'
Then I choose 'No'
Then I click 'Save and continue'
Then I should be on a page showing 'Check your answers'
diff --git a/features/providers/complete_and_check_means_answers.feature b/features/providers/complete_and_check_means_answers.feature
index f6d726584d..e4f2d9eac9 100644
--- a/features/providers/complete_and_check_means_answers.feature
+++ b/features/providers/complete_and_check_means_answers.feature
@@ -124,7 +124,7 @@ Feature: Completing and checking means answers backwards and forwards
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
When I choose "No"
Then I click 'Save and continue'
diff --git a/features/providers/non_passported_journey/with_capital.feature b/features/providers/non_passported_journey/with_capital.feature
index c1e26d1d63..4054b2d583 100644
--- a/features/providers/non_passported_journey/with_capital.feature
+++ b/features/providers/non_passported_journey/with_capital.feature
@@ -21,7 +21,7 @@ Feature: non_passported_journey with capital
Then I should be on a page with title "What you need to do"
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "Yes, with a mortgage or loan"
Then I click 'Save and continue'
Then I should be on a page showing "Your client's home"
diff --git a/features/providers/non_passported_journey/with_dependants.feature b/features/providers/non_passported_journey/with_dependants.feature
index c1fd862eba..76fda8f3e1 100644
--- a/features/providers/non_passported_journey/with_dependants.feature
+++ b/features/providers/non_passported_journey/with_dependants.feature
@@ -52,7 +52,7 @@ Feature: non_passported_journey with dependants
Then I should be on a page with title "What you need to do"
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "No"
Then I click 'Save and continue'
Then I should be on a page showing "Does your client own a vehicle?"
@@ -131,7 +131,7 @@ Feature: non_passported_journey with dependants
Then I should be on a page with title "What you need to do"
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "No"
Then I click 'Save and continue'
Then I should be on a page showing "Does your client own a vehicle?"
diff --git a/features/providers/non_passported_journey/with_means.feature b/features/providers/non_passported_journey/with_means.feature
index 9615743c45..4bcc73d376 100644
--- a/features/providers/non_passported_journey/with_means.feature
+++ b/features/providers/non_passported_journey/with_means.feature
@@ -85,7 +85,7 @@ Feature: non_passported_journey with means
And I should see "Tell us about your client's capital"
When I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
When I choose "No"
And I click 'Save and continue'
diff --git a/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature b/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
index db46f2aaad..93f59fa835 100644
--- a/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
+++ b/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
@@ -10,7 +10,7 @@ Feature: partner_means_assessment full journey
And I should see "Tell us about your client and their partner's capital"
When I click "Continue"
- Then I should be on a page with title "Does your client or their partner own the home your client lives in?"
+ Then I should be on a page with title "Does your client or their partner own the home your client usually lives in?"
When I choose "No"
And I click "Save and continue"
@@ -61,7 +61,7 @@ Feature: partner_means_assessment full journey
And I should see "Tell us about your client and their partner's capital"
When I click "Continue"
- Then I should be on a page with title "Does your client or their partner own the home your client lives in?"
+ Then I should be on a page with title "Does your client or their partner own the home your client usually lives in?"
Then I choose "Yes, with a mortgage or loan"
Then I click "Save and continue"
diff --git a/features/providers/passported_journey.feature b/features/providers/passported_journey.feature
index ce525e3944..1a390e9b4a 100644
--- a/features/providers/passported_journey.feature
+++ b/features/providers/passported_journey.feature
@@ -8,7 +8,7 @@ Feature: passported_journey completes application
Then I click 'Continue'
Then I should be on a page showing "What you need to do"
Then I click 'Continue'
- Then I should be on a page showing "Does your client own the home that they live in?"
+ Then I should be on a page showing "Does your client own the home they usually live in?"
Then I choose "Yes, with a mortgage or loan"
Then I click 'Save and continue'
Then I should be on a page showing "Your client's home"
@@ -49,7 +49,7 @@ Feature: passported_journey completes application
Then I enter the 'told' date of 2 days ago
Then I enter the 'occurred' date of 2 days ago
Then I click 'Save and continue'
- Then I should be on a page with title "Is the opponent an individual or an organisation?"
+ Then I should be on a page with title "Is the opponent an individual or an organisation?"
And I choose a 'An individual' radio button
When I click 'Save and continue'
Then I should be on a page with title "Opponent"
@@ -130,7 +130,7 @@ Feature: passported_journey completes application
And I click 'Save and continue'
Then I should be on a page showing "What you need to do"
And I click 'Continue'
- And I should be on a page showing 'Does your client own the home that they live in?'
+ And I should be on a page showing 'Does your client own the home they usually live in?'
@javascript @vcr
Scenario: A negative benefit check allows the solicitor to override the result
From f9ff66d3ea69eff38e77794737af2ee1e9dac0a8 Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Wed, 11 Dec 2024 16:40:48 +0000
Subject: [PATCH 16/20] AP-5383: Update payment list headings
---
.../bank_statement_upload/happy_path_journey.feature | 8 ++++----
.../bank_statement_upload/state_benefit_loop.feature | 8 ++++----
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/features/providers/bank_statement_upload/happy_path_journey.feature b/features/providers/bank_statement_upload/happy_path_journey.feature
index 8d5ab225e2..fc9bf3dde8 100644
--- a/features/providers/bank_statement_upload/happy_path_journey.feature
+++ b/features/providers/bank_statement_upload/happy_path_journey.feature
@@ -93,10 +93,10 @@ Feature: Bank statement upload journey happy path
Then the following sections should exist:
| tag | section |
| h2 | Government Cost of Living Payments |
- | h2 | Disregarded benefits |
- | h3 | Carer and disability benefits |
- | h3 | Low income benefits |
- | h3 | Other benefits |
+ | h2 | Disregarded benefits and payments |
+ | h3 | Carer and disability |
+ | h3 | Low income |
+ | h3 | Other |
When I choose "No"
And I click "Save and continue"
diff --git a/features/providers/bank_statement_upload/state_benefit_loop.feature b/features/providers/bank_statement_upload/state_benefit_loop.feature
index b4a7b26562..fd5a2e5b17 100644
--- a/features/providers/bank_statement_upload/state_benefit_loop.feature
+++ b/features/providers/bank_statement_upload/state_benefit_loop.feature
@@ -27,10 +27,10 @@ Feature: Bank statement upload journey state_benefit loop feature
Then the following sections should exist:
| tag | section |
| h2 | Government Cost of Living Payments |
- | h2 | Disregarded benefits |
- | h3 | Carer and disability benefits |
- | h3 | Low income benefits |
- | h3 | Other benefits |
+ | h2 | Disregarded benefits and payments |
+ | h3 | Carer and disability |
+ | h3 | Low income |
+ | h3 | Other |
When I choose "Yes"
And I click "Save and continue"
From 3d92045eff99f205f287a6efa0af85e8fa8016af Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Wed, 11 Dec 2024 17:02:01 +0000
Subject: [PATCH 17/20] AP-5383: Means report and review and print updates
---
.../means_report.feature | 19 +++++++------------
.../review_and_print.feature | 6 +++---
2 files changed, 10 insertions(+), 15 deletions(-)
diff --git a/features/providers/partner_means_assessment/means_report.feature b/features/providers/partner_means_assessment/means_report.feature
index e487a5fa29..316ab1c65c 100644
--- a/features/providers/partner_means_assessment/means_report.feature
+++ b/features/providers/partner_means_assessment/means_report.feature
@@ -22,7 +22,7 @@ Feature: Means report when partner is present
| h2 | Which savings or investments does either your client or their partner have? |
| h2 | Which assets does either your client or their partner have? |
| h2 | Restrictions on your client's or their partner's assets |
- | h2 | Your client's and the partner's payments from schemes or charities |
+ | h2 | Capital disregards |
| h3 | Bank statements |
Then the following sections should not exist:
@@ -130,11 +130,11 @@ Feature: Means report when partner is present
And the Property question should exist:
| question |
- | Does your client or their partner own the home that they live in? |
+ | Does your client or their partner own the home your client usually lives in? |
And the Property details questions should exist:
| question |
- | How much is the home your client and their partner live in worth? |
+ | How much is the home your client and their partner usually live in worth? |
| How much is left to pay on the mortgage? |
| Does your client or their partner own the home with anyone else? |
| What percentage of the home do your client and their partner legally own? |
@@ -188,12 +188,7 @@ Feature: Means report when partner is present
| Is your client or their partner banned from selling or borrowing against their assets? |
| Details of restrictions |
- And the "Payments from scheme or charities" questions should exist:
- | question |
- | England Infected Blood Support Scheme |
- | Vaccine Damage Payments Scheme |
- | Variant Creutzfeldt-Jakob disease (vCJD) Trust |
- | Criminal Injuries Compensation Scheme |
- | National Emergencies Trust (NET) |
- | We Love Manchester Emergency Fund |
- | The London Emergencies Trust |
+ And the Capital disregards questions and answers should match:
+ | question | answer |
+ | Mandatory disregards | Budgeting Advances\n£1,001 on 8 August 2024\nHeld in Halifax |
+ | Discretionary disregards | Compensation, damages or ex-gratia payments for personal harm\nFor: life changing injuries\n£1,002 on 8 August 2024\nHeld in Halifax |
diff --git a/features/providers/partner_means_assessment/review_and_print.feature b/features/providers/partner_means_assessment/review_and_print.feature
index beb62e8a2f..c9b7986d53 100644
--- a/features/providers/partner_means_assessment/review_and_print.feature
+++ b/features/providers/partner_means_assessment/review_and_print.feature
@@ -40,7 +40,7 @@ Feature: Review and print your application
| h2 | Which savings or investments does either your client or their partner have? |
| h2 | Which assets does either your client or their partner have? |
| h2 | Restrictions on your client's or their partner's assets |
- | h2 | Your client's and the partner's payments from schemes or charities |
+ | h2 | One-off payments your client or their partner received |
| h2 | Case details |
| h2 | Latest incident details |
| h2 | Opponent details |
@@ -83,7 +83,7 @@ Feature: Review and print your application
| h2 | Which savings or investments does either your client or their partner have? |
| h2 | Which assets does either your client or their partner have? |
| h2 | Restrictions on your client's or their partner's assets |
- | h2 | Your client's and the partner's payments from schemes or charities |
+ | h2 | One-off payments your client or their partner received |
| h2 | Case details |
| h2 | Latest incident details |
| h2 | Opponent details |
@@ -121,7 +121,7 @@ Feature: Review and print your application
| h2 | Which savings or investments does either your client or their partner have? |
| h2 | Which assets does either your client or their partner have? |
| h2 | Restrictions on your client's or their partner's assets |
- | h2 | Your client's and the partner's payments from schemes or charities |
+ | h2 | One-off payments your client or their partner received |
| h2 | Case details |
| h2 | Latest incident details |
| h2 | Opponent details |
From 3b70ff42e505dc56d403760d087933da1c37333e Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Wed, 11 Dec 2024 17:22:26 +0000
Subject: [PATCH 18/20] AP-5383: More partner feature updates
---
.../end_to_end_capital_assessment.feature | 20 +++++++++++++------
1 file changed, 14 insertions(+), 6 deletions(-)
diff --git a/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature b/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
index 93f59fa835..620e8a5670 100644
--- a/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
+++ b/features/providers/partner_means_assessment/end_to_end_capital_assessment.feature
@@ -44,10 +44,14 @@ Feature: partner_means_assessment full journey
When I choose "No"
And I click "Save and continue"
- Then I should be on a page with title "Which schemes or trusts have paid either your client or their partner?"
+ Then I should be on a page showing "Disregarded payments"
- When I select "None of these schemes or trusts"
- And I click "Save and continue"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I should be on a page with title "Check your answers"
@javascript
@@ -108,8 +112,12 @@ Feature: partner_means_assessment full journey
When I choose "Yes"
And I fill "restrictions_details" with "Some details of restrictions"
And I click "Save and continue"
- Then I should be on a page with title "Which schemes or trusts have paid either your client or their partner?"
+ Then I should be on a page showing "Disregarded payments"
- When I select "Criminal Injuries Compensation Scheme"
- And I click "Save and continue"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I should be on a page with title "Check your answers"
From 8812892cb2f89c151651de0069b915b65a9c4b5b Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Thu, 12 Dec 2024 09:56:16 +0000
Subject: [PATCH 19/20] AP-5383: Update more feature tests to reflect MTR-2A
changes
---
.../complete_and_check_means_answers.feature | 7 +++++--
.../non_passported_journey/with_capital.feature | 9 ++++++---
.../non_passported_journey/with_dependants.feature | 14 ++++++++++----
.../non_passported_journey/with_means.feature | 14 ++++++++++++--
features/providers/passported_journey.feature | 7 +++++--
5 files changed, 38 insertions(+), 13 deletions(-)
diff --git a/features/providers/complete_and_check_means_answers.feature b/features/providers/complete_and_check_means_answers.feature
index e4f2d9eac9..4fbcc900a7 100644
--- a/features/providers/complete_and_check_means_answers.feature
+++ b/features/providers/complete_and_check_means_answers.feature
@@ -144,11 +144,14 @@ Feature: Completing and checking means answers backwards and forwards
When I select "None of these assets"
And I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
+ Then I should be on a page showing "Disregarded payments"
- When I select 'England Infected Blood Support Scheme'
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
diff --git a/features/providers/non_passported_journey/with_capital.feature b/features/providers/non_passported_journey/with_capital.feature
index 4054b2d583..65e0e45882 100644
--- a/features/providers/non_passported_journey/with_capital.feature
+++ b/features/providers/non_passported_journey/with_capital.feature
@@ -65,9 +65,12 @@ Feature: non_passported_journey with capital
Then I choose 'Yes'
Then I fill 'Restrictions details' with 'Yes, there are restrictions. They include...'
Then I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
- Then I select 'England Infected Blood Support Scheme'
- Then I click 'Save and continue'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
@javascript @vcr
diff --git a/features/providers/non_passported_journey/with_dependants.feature b/features/providers/non_passported_journey/with_dependants.feature
index 76fda8f3e1..045f99147b 100644
--- a/features/providers/non_passported_journey/with_dependants.feature
+++ b/features/providers/non_passported_journey/with_dependants.feature
@@ -67,8 +67,11 @@ Feature: non_passported_journey with dependants
Then I should be on a page showing "Which assets does your client have?"
Then I select "None of these assets"
Then I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
- When I select 'England Infected Blood Support Scheme'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
@@ -146,7 +149,10 @@ Feature: non_passported_journey with dependants
Then I should be on a page showing "Which assets does your client have?"
Then I select "None of these assets"
Then I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
- When I select 'England Infected Blood Support Scheme'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
diff --git a/features/providers/non_passported_journey/with_means.feature b/features/providers/non_passported_journey/with_means.feature
index 4bcc73d376..724c383402 100644
--- a/features/providers/non_passported_journey/with_means.feature
+++ b/features/providers/non_passported_journey/with_means.feature
@@ -111,9 +111,19 @@ Feature: non_passported_journey with means
When I choose 'Yes'
And I fill 'Restrictions details' with 'Yes, there are restrictions. They include...'
And I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
+ Then I should be on a page showing "Disregarded payments"
- When I select 'England Infected Blood Support Scheme'
+ When I check "Infected Blood Support Scheme payment"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Add details for 'Infected Blood Support Scheme payment'"
+
+ When I fill "amount" with "100"
+ And I fill 'account name' with 'Halifax'
+ And I enter the 'date received' date of 20 days ago
+ And I click "Save and continue"
+ Then I should be on a page showing "Payments to be reviewed"
+
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on the 'check_capital_answers' page showing 'Check your answers'
diff --git a/features/providers/passported_journey.feature b/features/providers/passported_journey.feature
index 1a390e9b4a..9e465ff674 100644
--- a/features/providers/passported_journey.feature
+++ b/features/providers/passported_journey.feature
@@ -36,8 +36,11 @@ Feature: passported_journey completes application
Then I choose 'Yes'
Then I fill 'Restrictions details' with 'Yes, there are restrictions. They include...'
Then I click 'Save and continue'
- Then I should be on the 'policy_disregards' page showing 'schemes or trusts'
- When I select 'None of these schemes or trusts'
+ Then I should be on a page showing "Disregarded payments"
+ When I check "My client has not received any of these payments"
+ And I click 'Save and continue'
+ Then I should be on a page showing "Payments to be reviewed"
+ When I check "My client has not received any of these payments"
And I click 'Save and continue'
Then I should be on a page showing "Check your answers"
Then I click 'Save and continue'
From 769b0886f138b7e27e993da3120a1beb78bf66dc Mon Sep 17 00:00:00 2001
From: Adam Goldstone <13471320+agoldstone93@users.noreply.github.com>
Date: Thu, 12 Dec 2024 11:40:05 +0000
Subject: [PATCH 20/20] AP-5383: Update one of payments heading post MTR-A
---
features/providers/check_your_answers.feature | 4 ++--
features/providers/means_report.feature | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/features/providers/check_your_answers.feature b/features/providers/check_your_answers.feature
index 01b65aca5d..879e7f2b70 100644
--- a/features/providers/check_your_answers.feature
+++ b/features/providers/check_your_answers.feature
@@ -320,7 +320,7 @@ Feature: Checking answers backwards and forwards
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | One-off payments your client received |
And the "Payments your client receives" section's questions and answers should match:
| question | answer |
@@ -352,7 +352,7 @@ Feature: Checking answers backwards and forwards
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | One-off payments your client received |
Then the following sections should not exist:
| tag | section |
diff --git a/features/providers/means_report.feature b/features/providers/means_report.feature
index 2f7023d33a..40e73bde15 100644
--- a/features/providers/means_report.feature
+++ b/features/providers/means_report.feature
@@ -425,7 +425,7 @@ Feature: Means report
| h2 | Which savings or investments does your client have? |
| h2 | Which assets does your client have? |
| h2 | Restrictions on your client's assets |
- | h2 | Payments from scheme or charities |
+ | h2 | One-off payments your client received |
| h2 | Capital disregards |
| h3 | Bank statements |
| h3 | Your client's accounts|